joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4013fa
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x444
push ebx
push 0x40e0c0
call fcn.00407460
xor ebx, ebx
mov dword [esp], str.Jd_
push ebx
mov dword [ebp - 0x14], eax
call fcn.004052d3
push ebx
push 0x40fba1
call fcn.00403464
add esp, 0x10
mov dword [ebp - 4], eax
lea eax, [ebp - 0x444]
push 0x104
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push dword [ebp + 8]
mov dword [ebp - 0x340], 0x224
push 8
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
lea ecx, [ebp - 0x340]
mov dword [ebp - 0x18], eax
push ecx
push eax
call sub.KERNEL32.dll_Module32First
test eax, eax
je 0x4015ef
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x11c]
push eax
call fcn.00407370
lea eax, [ebp - 0x11c]
push eax
lea eax, [ebp - 0x444]
push eax
call fcn.0040c540
add esp, 0x10
test eax, eax
je 0x4015ef
push dword [ebp - 0x338]
push ebx
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
cmp eax, ebx
mov dword [ebp - 0xc], eax
je 0x4015ef
push esi
mov esi, 0x80000
push edi
push esi
mov edi, 0x411970
push ebx
push edi
call fcn.00407310
mov eax, dword [ebp - 0x328]
add esp, 0xc
cmp eax, esi
jb 0x4014e1
mov eax, esi
cmp dword [ebp + 0xc], ebx
mov dword [ebp - 8], ebx
jne 0x401506
lea ecx, [ebp - 8]
push ecx
push eax
push edi
push dword [ebp - 0x32c]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
je 0x4015e1
cmp dword [ebp - 4], ebx
mov dword [ebp + 8], ebx
jbe 0x4015e1
push dword [ebp + 8]
push 0x40fba1
call fcn.00403434
push eax
mov dword [ebp - 0x10], eax
call fcn.00407460
xor esi, esi
add esp, 0xc
cmp dword [ebp + 0xc], esi
mov ebx, eax
je 0x40153c
lea eax, [ebx + 0x6e]
mov dword [ebp - 8], eax
jmp 0x40153f
mov eax, dword [ebp - 8]
sub eax, ebx
sub eax, 0xa
je 0x4015d2
push dword [ebp - 0x14]
lea edi, [esi + 0x411970]
push edi
push 0x40e0c0
call fcn.0040c490
add esp, 0xc
test eax, eax
je 0x4015cb
cmp dword [ebp + 0xc], 0
jne 0x40158b
push ebx
push edi
push dword [ebp - 0x10]
call fcn.0040c490
add esp, 0xc
test eax, eax
je 0x40158b
mov eax, dword [ebp - 8]
inc esi
sub eax, ebx
sub eax, 0xa
cmp esi, eax
jb 0x40154a
jmp 0x4015d2
push 0
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push 0x32
call dword [sym.imp.KERNEL32.dll_Sleep]
push 1
push str.d__b
call fcn.00403434
push eax
lea eax, [ebp - 0x11c]
push eax
call fcn.00403b7d
add esp, 0x10
test eax, eax
jne 0x4015cb
lea eax, [ebp - 0x11c]
push eax
call fcn.00403dfa
pop ecx
mov eax, dword [ebp - 4]
inc eax
mov dword [ebp + 8], eax
inc dword [ebp + 8]
mov eax, dword [ebp + 8]
cmp eax, dword [ebp - 4]
jb 0x401512
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 1
pop ebx
pop edi
pop esi
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
pop ebx
leave
ret 8
Function at 0x4048cb
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x51c
and dword [ebp - 4], 0
cmp dword [0x491e88], 0
jne 0x404906
push 4
push 0x40f244
call fcn.00403434
lea ecx, [ebp - 4]
push ecx
push 0x4047fd
push eax
push closesocket
call fcn.00404562
add esp, 0x18
jmp 0x404942
lea eax, [ebp - 0x418]
push 2
push eax
call fcn.00403bd8
lea eax, [ebp - 0x418]
push eax
push 0x491a78
call fcn.00407370
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x418]
push 0x404769
push eax
push closesocket
call fcn.004045e0
add esp, 0x20
mov eax, dword [ebp - 4]
test eax, eax
mov dword [0x491e8c], eax
jne 0x404a23
push esi
lea eax, [ebp - 0x51c]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
xor esi, esi
and byte [ebp - 0x18], 0
lea eax, [ebp - 0x18]
push str.B_0:
push eax
call fcn.00407370
pop ecx
lea eax, [ebp - 0x18]
pop ecx
push 4
push 4
push 2
push eax
call fcn.00407460
pop ecx
lea eax, [ebp + eax - 0x18]
push eax
call fcn.00403624
lea eax, [ebp - 0x17]
push eax
call fcn.0040c5cc
lea eax, [ebp - 0x51c]
push eax
lea eax, [ebp - 0x418]
push eax
call fcn.00407370
lea eax, [ebp - 0x418]
push 0x40e044
push eax
call fcn.00407380
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x418]
push eax
call fcn.00407380
lea eax, [ebp - 0x418]
push 0x40f1dc
push eax
call fcn.00407380
lea eax, [ebp - 0x418]
push eax
call fcn.00403d58
add esp, 0x38
test eax, eax
je 0x404a00
inc esi
cmp esi, 0xa
jl 0x404967
lea eax, [ebp - 0x18]
push eax
push 0x491974
call fcn.00407380
lea eax, [ebp - 0x418]
push eax
push 0x491b7c
call fcn.00407370
add esp, 0x10
pop esi
push 1
pop eax
leave
ret

Function at 0x404b78
Capabilities:
Parse pe header

Disassembly:
push esi
mov esi, dword [esp + 0xc]
cmp esi, 0x44
jb 0x404bb3
mov ecx, dword [esp + 8]
cmp byte [ecx], 0x4d
jne 0x404bb3
cmp byte [ecx + 1], 0x5a
jne 0x404bb3
movzx eax, word [ecx + 0x3c]
add eax, ecx
add esi, 0xfffffffc
mov edx, eax
sub edx, ecx
cmp edx, esi
ja 0x404bb3
mov eax, dword [eax]
pop esi
sub eax, 0x4550
neg eax
sbb eax, eax
not eax
and eax, edx
ret
xor eax, eax
pop esi
ret
Function at 0x4053ac
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
push ebx
push esi
push edi
push 1
pop ebx
push ebx
call fcn.00404687
mov esi, 0x104
xor edi, edi
push esi
push edi
push 0x491d84
call fcn.00407310
push esi
push edi
push 0x491c80
call fcn.00407310
push esi
push edi
push 0x491b7c
call fcn.00407310
push esi
push edi
push 0x491a78
call fcn.00407310
push esi
push edi
push 0x491974
call fcn.00407310
add esp, 0x40
push 0x40e0d0
push 0x1eac
push 0x40e0d4
call fcn.00403529
push 0x491e90
call fcn.00402642
add esp, 0x10
call dword [sym.imp.KERNEL32.dll_GetVersion]
and eax, 0x80000000
mov dword [0x491e98], edi
mov dword [0x491e88], eax
lea eax, [ebp - 0x94]
push eax
mov dword [ebp - 0x94], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x90], 5
jne 0x40546c
cmp dword [ebp - 0x8c], ebx
jne 0x40546c
mov dword [0x491e98], ebx
call fcn.004048cb
mov esi, 0x7d000
push esi
call fcn.00407baf
cmp eax, edi
pop ecx
mov dword [0x491970], eax
jne 0x40548a
xor eax, eax
jmp 0x4054ae
push esi
push edi
push eax
call fcn.00407310
call fcn.0040556c
push ebx
push str.Jd_
call fcn.00403434
push eax
push edi
call fcn.004052d3
add esp, 0x1c
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret

Function at 0x40556c
Capabilities:
Link many functions at runtime

Disassembly:
push ebx
push ebp
push esi
push edi
push 2
push 0x40fb6f
call fcn.00403434
mov ebx, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
pop ecx
pop ecx
push eax
call ebx
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ebp, eax
test ebp, ebp
mov edi, str.H___n
je 0x4055d1
push 1
push edi
call fcn.00403434
pop ecx
pop ecx
push eax
push ebp
call esi
push 4
push edi
mov dword [0x491ea0], eax
call fcn.00403434
pop ecx
pop ecx
push eax
push ebp
call esi
push 5
push edi
mov dword [0x491e9c], eax
call fcn.00403434
pop ecx
pop ecx
push eax
push ebp
call esi
mov dword [0x491ea4], eax
push 3
push 0x40fb6f
call fcn.00403434
pop ecx
pop ecx
push eax
call ebx
mov ebp, eax
test ebp, ebp
je 0x4055fb
push 3
push edi
call fcn.00403434
pop ecx
pop ecx
push eax
push ebp
call esi
mov dword [0x491ea8], eax
mov edi, 0x40fda4
push edi
call ebx
mov ebx, eax
test ebx, ebx
je 0x40561c
push 1
push edi
call fcn.00403434
pop ecx
pop ecx
push eax
push ebx
call esi
mov dword [0x491eac], eax
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x4058b1
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x324
push esi
lea ecx, [ebp - 0x18]
call fcn.0040174b
and dword [ebp - 4], 0
lea eax, [ebp - 8]
push 1
push eax
push dword [ebp + 8]
lea ecx, [ebp - 0x18]
call fcn.0040174e
mov esi, eax
test esi, esi
je 0x405967
lea eax, [ebp - 0x324]
push 0
push eax
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x11c]
push eax
push dword [ebp + 8]
call fcn.004074db
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x11c]
push eax
call fcn.00407380
lea eax, [ebp - 0x324]
push eax
lea eax, [ebp - 0x11c]
push eax
call fcn.00407380
lea eax, [ebp - 0x11c]
push 0x40f1d8
push eax
call fcn.00407380
lea eax, [ebp - 0x11c]
push 0x40f1dc
push eax
call fcn.00407380
lea eax, [ebp - 4]
push eax
push dword [ebp - 8]
push esi
call fcn.00407196
mov esi, eax
add esp, 0x40
test esi, esi
lea ecx, [ebp - 0x18]
jne 0x40596b
call fcn.00401808
xor eax, eax
jmp 0x4059bf
call fcn.00401808
push dword [ebp - 4]
lea eax, [ebp - 0x11c]
push esi
push eax
call fcn.00403cbb
push esi
call fcn.0040780b
add esp, 0x10
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
push eax
lea eax, [ebp - 0x11c]
push eax
call fcn.004046b3
pop ecx
test eax, eax
pop ecx
je 0x4059bd
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x11c]
push eax
call fcn.00403dfa
pop ecx
push 1
pop esi
mov eax, esi
pop esi
leave
ret

Function at 0x405e9a
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
and byte [ebp - 0x10c], 0
push ebx
lea eax, [ebp - 0x10c]
push 0x104
push eax
push 1
push str.rjN
call fcn.00403434
pop ecx
pop ecx
push eax
push 0x40f244
push closesocket
call fcn.004044c0
lea eax, [ebp - 0x10c]
push eax
call fcn.00405c5a
movsx eax, byte [ebp - 0x10c]
mov bl, byte [ebp - 0x10a]
push eax
call fcn.004076ee
add esp, 0x1c
and dword [ebp - 8], 0
mov byte [ebp - 1], al
mov al, byte [ebp - 8]
add al, 0x61
cmp al, byte [ebp - 1]
je 0x405f44
and byte [ebp - 0x10a], 0
mov byte [ebp - 0x10c], al
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 3
mov byte [ebp - 0x10a], bl
jne 0x405f44
push dword [ebp + 8]
lea eax, [ebp - 0x10c]
push 0x405e42
push eax
call fcn.00403e11
add esp, 0xc
inc dword [ebp - 8]
cmp dword [ebp - 8], 0x1a
jl 0x405efe
xor eax, eax
pop ebx
leave
ret 4
Function at 0x406820
Capabilities:
Copy file
Create service
Persist via windows service
Set file attributes
Start service

Disassembly:
mov eax, 0x1fc8
call fcn.00407b80
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x14]
push 0x104
xor ebx, ebx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
mov edi, dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov esi, 0x491b7c
push 0x20
push esi
call edi
push ebx
lea eax, [esp + 0x18]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
push 0x20
push esi
mov dword [esp + 0x18], eax
call edi
cmp dword [esp + 0x10], ebx
je 0x4068c3
push 0x1ec0
lea eax, [esp + 0x11c]
push 0x40e0c0
push eax
call fcn.00407820
lea eax, [esp + 0x124]
mov byte [esp + 0x1138], bl
push eax
push esi
call fcn.004054b3
push 0x13000
push esi
call fcn.00404e60
push ebx
call fcn.00404687
xor edx, edx
mov ecx, 0x2800
div ecx
add edx, 0x13200
push edx
push esi
call fcn.00403f63
add esp, 0x28
push 0x27
push esi
call edi
cmp dword [0x491e88], ebx
mov edi, 0x491974
je 0x40691a
push esi
push edi
push 0x491a78
push closesocket
call fcn.0040451c
push 1
push 0x40fb6f
call fcn.00403434
add esp, 0x18
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ebp, eax
push str.H___n
push ebp
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x406913
push 1
push ebx
call eax
push ebp
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp dword [esp + 0x10], ebx
jne 0x406924
xor eax, eax
jmp 0x406999
cmp dword [0x491e88], ebx
je 0x406937
push ebx
push esi
call fcn.004046b3
pop ecx
pop ecx
jmp 0x406996
cmp dword [0x491e90], ebx
jne 0x406996
mov ebp, dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
push 2
push ebx
push ebx
call ebp
push ebx
push ebx
push ebx
push ebx
push ebx
push esi
push ebx
push 2
push 0x110
push ebx
push edi
push edi
push eax
mov dword [esp + 0x44], eax
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
push dword [esp + 0x10]
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push 1
push ebx
push ebx
call ebp
mov ebp, eax
push 0x10
push edi
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
push ebx
push ebx
push edi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
push edi
call esi
push ebp
call esi
push 1
pop eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1fc8
ret
Function at 0x401af0
Capabilities:
Get disk information
Get disk size
Get volume information via ioctl

Disassembly:
sub esp, 0x18c
mov eax, dword [0x42fcec]
xor eax, esp
mov dword [esp + 0x184], eax
mov eax, dword [0x429e2c]
mov ecx, dword [0x429e30]
push 0x80
lea edx, [esp + 0x84]
push edx
push 0
push 0
push 0
push 0
mov dword [esp + 0x90], eax
push 0
lea eax, [esp + 0x94]
push eax
mov dword [esp + 0x9c], ecx
mov word [esp + 0x98], di
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
mov ecx, str.NTFS
lea eax, [esp + 0x80]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x401b7c
test dx, dx
je 0x401b78
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x401b7c
add eax, 4
add ecx, 4
test dx, dx
jne 0x401b56
xor eax, eax
jmp 0x401b81
sbb eax, eax
sbb eax, 0xffffffff
xor ecx, ecx
test eax, eax
sete cl
lea edx, [esp + 0x80]
push edx
push 0x40
push 0x433e4e
mov word [0x433e4c], di
mov dword [0x443f60], ecx
call fcn.00413feb
add esp, 0xc
cmp dword [0x443f60], 0
je 0x401c2c
mov edx, dword [0x443f10]
push 0
lea eax, [esp + 0x18]
push eax
push 0x60
lea ecx, [esp + 0x24]
push ecx
push 0
push 0
push 0x90064
push edx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x401bf2
mov ecx, dword [esp + 0x184]
xor ecx, esp
call fcn.00413fdc
add esp, 0x18c
ret
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x30]
mov dword [0x433df8], eax
mov eax, dword [esp + 0x34]
mov dword [0x433e08], edx
mov dword [0x433e0c], eax
mov eax, dword [esp + 0x44]
mov dword [0x433dfc], ecx
mov ecx, dword [esp + 0x40]
xor edx, edx
mov dword [0x433e24], ecx
div ecx
jmp 0x401c83
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x88]
push edx
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceW]
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 8]
mov dword [0x433df8], eax
mov eax, dword [esp + 4]
mov dword [0x433dfc], 0
mov dword [0x433e08], ecx
mov dword [0x433e0c], 0
mov dword [0x433e24], edx
mov ecx, dword [esp + 0x184]
mov dword [0x433e20], eax
xor ecx, esp
mov eax, 1
call fcn.00413fdc
add esp, 0x18c
ret
Function at 0x401f20
Capabilities:
Get volume information via ioctl

Disassembly:
mov edx, dword [esi + 0x10178]
sub esp, 0x90
push ebx
push ebp
push edi
xor edi, edi
push edi
lea eax, [esp + 0x38]
push eax
push 0x60
lea ecx, [esp + 0x44]
push ecx
push edi
push edi
push 0x90064
push edx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x401f66
call dword [sym.imp.KERNEL32.dll_GetLastError]
dec eax
neg eax
sbb eax, eax
inc eax
pop edi
pop ebp
pop ebx
add esp, 0x90
ret
mov eax, dword [esp + 0x90]
mov ebx, dword [esp + 0x94]
mov ebp, dword [esp + 0x8c]
mov ecx, dword [esp + 0x88]
add eax, 0xffffffff
push 1
adc ebx, 0xffffffff
push ebx
push eax
push ebp
mov dword [esp + 0x30], eax
push ecx
lea eax, [esi + 0x10188]
push eax
mov dword [esp + 0x28], ecx
mov dword [esp + 0x2c], ebp
call fcn.00401950
xor edx, edx
cmp dword [esi + 0x10180], edi
jbe 0x401fcc
xor eax, eax
mov ecx, dword [esi + 0x1017c]
mov dword [ecx + eax + 0x20], edi
mov dword [ecx + eax + 0x24], edi
inc edx
add eax, 0x28
cmp edx, dword [esi + 0x10180]
jb 0x401fb2
mov edi, dword [esi + 0x10184]
mov ecx, dword [esp + 0x10]
push 0
push edi
push ebp
push ecx
call fcn.00424b20
imul edi, eax
xor ecx, ecx
cmp ecx, ebx
ja 0x4020ab
jb 0x401ff9
cmp edi, dword [esp + 0x20]
ja 0x4020ab
lea ecx, [eax + eax*4]
add ecx, ecx
add ecx, ecx
add ecx, ecx
lea edx, [eax + 1]
mov dword [esp + 0x1c], ecx
mov dword [esp + 0xc], edx
jmp 0x402014
mov ebp, dword [esp + 0x14]
mov edx, dword [esi + 0x10184]
mov ecx, dword [esp + 0xc]
imul ecx, edx
mov edi, edx
mov dword [esp + 0x2c], 0
imul edi, eax
dec ecx
xor edx, edx
cmp dword [esp + 0x2c], ebp
ja 0x40204b
jb 0x402043
cmp edi, dword [esp + 0x10]
jae 0x40204b
mov ebp, dword [esp + 0x14]
mov edi, dword [esp + 0x10]
mov dword [esp + 0x2c], ebp
cmp edx, ebx
jb 0x40205d
ja 0x402057
cmp ecx, dword [esp + 0x20]
jbe 0x40205d
mov ecx, dword [esp + 0x20]
mov edx, ebx
mov ebp, dword [esp + 0x1c]
sub ecx, edi
sbb edx, dword [esp + 0x2c]
add ecx, 1
adc edx, 0
mov edi, edx
mov edx, dword [esi + 0x1017c]
add dword [edx + ebp + 0x20], ecx
lea edx, [edx + ebp + 0x20]
adc dword [edx + 4], edi
mov ecx, dword [esi + 0x10184]
inc dword [esp + 0xc]
inc eax
add ebp, 0x28
imul ecx, eax
xor edx, edx
mov dword [esp + 0x1c], ebp
cmp edx, ebx
jb 0x402010
ja 0x4020ab
cmp ecx, dword [esp + 0x20]
jbe 0x402010
pop edi
pop ebp
mov eax, 1
pop ebx
add esp, 0x90
ret
Function at 0x403c10
Capabilities:
Get file size

Disassembly:
sub esp, 0x30
push ebx
push ebp
mov ebp, dword [esp + 0x3c]
xor ebx, ebx
push edi
lea eax, [esp + 0x10]
push eax
mov edi, 1
push ebp
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x48], edi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov dword [esi + 0xa0], ecx
push ebp
lea ecx, [esp + 0x1c]
mov dword [esi + 0xa4], edx
call fcn.00402af0
test eax, eax
jne 0x403c79
mov dword [esp + 0x40], ebx
jmp 0x403cf8
mov ecx, dword [esp + 0x28]
cmp ecx, edi
jbe 0x403ca3
xor eax, eax
add dword [esi + 0x50], ecx
adc dword [esi + 0x54], eax
add dword [esi + 0x58], ecx
mov ecx, dword [esp + 0x14]
adc dword [esi + 0x5c], eax
add dword [esi + 0x38], edi
mov eax, dword [esp + 0x10]
adc dword [esi + 0x3c], ebx
add dword [esi + 0x40], eax
adc dword [esi + 0x44], ecx
push esi
lea edi, [esp + 0x1c]
call fcn.00402510
cmp byte [esp + 0x44], bl
jne 0x403cd6
mov ecx, esi
cmp dword [esi + 0x101d0], ebx
jne 0x403cc7
push ebp
mov edx, edi
call fcn.004032d0
jmp 0x403cd2
lea ebx, [esp + 0x18]
call fcn.00403830
xor ebx, ebx
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x18]
add dword [esi + 0x78], eax
mov ecx, dword [esp + 0x1c]
adc dword [esi + 0x7c], ecx
cmp dword [esi + 0xb0], ebx
je 0x403cf8
add dword [esi + 0x80], eax
adc dword [esi + 0x84], ecx
mov edx, dword [esp + 0x34]
push edx
call fcn.00407d1d
mov eax, dword [esp + 0x44]
add esp, 4
pop edi
pop ebp
pop ebx
add esp, 0x30
ret 8
Function at 0x406110
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push edi
mov edi, dword [esp + 0x10]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x406129
pop edi
pop ebx
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x406164
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [esp + 0x18]
add eax, esi
and ecx, 0xf
jbe 0x406160
lea ebx, [ebx]
cmp esi, eax
jae 0x406164
sub ecx, 1
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x406150
cmp esi, eax
jb 0x40616a
pop esi
pop edi
xor eax, eax
pop ebx
ret
movzx eax, word [esi]
neg eax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
ret

Function at 0x4069f0
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x20064
call fcn.00417a80
mov eax, dword [0x42fcec]
xor eax, esp
mov dword [esp + 0x20060], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 0x10]
push 0
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call fcn.004093ea
mov eax, dword [ebp + 8]
push eax
lea esi, [esp + 0x14]
call fcn.00406f60
movzx eax, word [edi]
mov dword [esp + 0x2005c], 0
mov dword [esp + 0x10], vtable.CService.0
mov dword [esp + 0x20058], 0x42a3cc
cmp ax, 0x2d
je 0x406aac
cmp ax, 0x2f
je 0x406aac
call fcn.00407350
mov esi, eax
mov eax, dword [esp + 0x20028]
mov dword [esp + 0x20058], 0x42a398
mov dword [esp + 0x10], vtable.CServiceTemplate.0
test eax, eax
je 0x406af1
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x20060]
xor ecx, esp
call fcn.00413fdc
mov esp, ebp
pop ebp
ret 0x10
add edi, 2
push edi
push 0x42a374
call fcn.00414a2a
add esp, 8
test eax, eax
jne 0x406b0a
lea eax, [esp + 0x10]
call fcn.004070d0
mov esi, eax
mov eax, dword [esp + 0x20028]
mov dword [esp + 0x20058], 0x42a398
mov dword [esp + 0x10], vtable.CServiceTemplate.0
test eax, eax
je 0x406af1
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x20060]
xor ecx, esp
call fcn.00413fdc
mov esp, ebp
pop ebp
ret 0x10
push edi
push str.remove
call fcn.00414a2a
add esp, 8
test eax, eax
jne 0x406b65
lea ebx, [esp + 0x10]
call fcn.004071e0
mov esi, eax
mov eax, dword [esp + 0x20028]
mov dword [esp + 0x20058], 0x42a398
mov dword [esp + 0x10], vtable.CServiceTemplate.0
test eax, eax
je 0x406af1
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x20060]
xor ecx, esp
call fcn.00413fdc
mov esp, ebp
pop ebp
ret 0x10
mov eax, dword [esp + 0x20028]
mov dword [esp + 0x20058], 0x42a398
mov dword [esp + 0x10], vtable.CServiceTemplate.0
test eax, eax
je 0x406b8a
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0x2006c]
pop edi
pop esi
pop ebx
xor ecx, esp
mov eax, 0x3e9
call fcn.00413fdc
mov esp, ebp
pop ebp
ret 0x10
Function at 0x406db0
Capabilities:
Create thread

Disassembly:
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_CreateEventW]
push 0
push 0
push 0
push 0
mov esi, ecx
call edi
push 0
push 0
push 1
push 0
mov dword [0x433ca8], eax
call edi
push 0
push 0
push 1
push 0
mov dword [0x433c94], eax
call edi
mov edi, dword [sym.imp.KERNEL32.dll_CreateThread]
push 0
push 0
push 0x43117c
mov dword [0x433c90], eax
mov eax, dword [esi + 0x20018]
push 0x406f40
mov dword [0x431180], eax
mov ecx, dword [esi + 0x20018]
push 0
push 0
mov dword [esi + 0x2004c], ecx
call edi
push 0
push 0
lea edx, [esi + 0x20048]
push edx
push 0x406f40
push 0
push 0
mov dword [esi + 0x20050], eax
call edi
mov dword [esi + 0x20054], eax
pop edi
mov eax, 1
pop esi
ret

Function at 0x406ed0
Capabilities:
Suspend thread

Disassembly:
mov eax, dword [0x43118c]
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_SuspendThread]
push eax
mov esi, ecx
call edi
mov ecx, dword [esi + 0x20054]
push ecx
call edi
pop edi
mov eax, 1
pop esi
ret

Function at 0x406f00
Capabilities:
Resume thread

Disassembly:
mov eax, dword [0x43118c]
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ResumeThread]
push eax
mov esi, ecx
call edi
mov ecx, dword [esi + 0x20054]
push ecx
call edi
pop edi
mov eax, 1
pop esi
ret

Function at 0x4070d0
Capabilities:
Create service
Persist via run registry key
Persist via windows service
Set registry value

Disassembly:
push ecx
push ebp
push esi
mov esi, eax
xor ebp, ebp
cmp dword [esi + 4], 4
push edi
jl 0x407171
push 0xf003f
push ebp
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov edi, eax
test edi, edi
jne 0x407108
mov eax, dword [esi]
mov edx, dword [eax + 4]
push 0x3eb
mov ecx, esi
call edx
pop edi
pop esi
pop ebp
pop ecx
ret
mov eax, dword [esi + 0x14]
push ebx
mov edx, dword [esi + 0x10]
push 0
push 0
push eax
mov eax, dword [esi + 0xc]
push 0
push 0
lea ecx, [esi + 0x10018]
push ecx
push 1
push 2
push 0x10
push 0xf01ff
push edx
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov ebx, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test eax, eax
jne 0x407152
mov edx, dword [esi]
mov eax, dword [edx + 4]
push 0x3eb
mov ecx, esi
call eax
mov ebp, eax
jmp 0x407155
push eax
call ebx
push edi
call ebx
mov ecx, dword [esi + 0xc]
push ecx
push str._s_service_installed._n
call fcn.00414d84
add esp, 8
pop ebx
pop edi
pop esi
mov eax, ebp
pop ebp
pop ecx
ret
lea edx, [esp + 0xc]
push edx
push str.SoftwareMicrosoftWindowsCurrentVersionRun
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x4071c3
add esi, 0x10018
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [esp + 0xc]
lea eax, [eax + eax + 2]
push eax
push esi
push 1
push 0
push str.DCDiskOptimizer
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edx, dword [esp + 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
mov eax, ebp
pop ebp
pop ecx
ret
push 0
push 0x42a494
push 0x42a494
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
pop edi
pop esi
mov eax, ebp
pop ebp
pop ecx
ret