joyce8/EMBER2024-capa huggingface dataset:
Function at 0x457c70
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x110
mov eax, dword [0x51e584]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
cmp dword [esi + 0x1a4], 0
mov ebx, dword [esi]
push edi
mov dword [ebp - 0x108], esi
mov dword [ebp - 0x110], ebx
jne 0x457e07
mov edi, dword [ebp + 0xc]
lea eax, [ebp - 0x10c]
push eax
lea ecx, [ebp - 0x104]
push ecx
push edi
mov dword [ebp - 0x10c], 0x80
call dword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x457cfa
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
push edi
push esi
call fcn.0045a6e0
push eax
push edi
push str.getpeername___failed_with_errno__d:__s
push ebx
call fcn.00455a20
add esp, 0x18
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004815a9
mov esp, ebp
pop ebp
ret
lea edx, [ebp - 0x10c]
push edx
lea eax, [ebp - 0x84]
push eax
push edi
mov dword [ebp - 0x10c], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x457d4d
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
push edi
push esi
call fcn.0045a6e0
push eax
push edi
push str.getsockname___failed_with_errno__d:__s
push ebx
call fcn.00455a20
add esp, 0x18
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004815a9
mov esp, ebp
pop ebp
ret
lea ebx, [esi + 0xcc]
lea edi, [esi + 0x9e]
lea esi, [ebp - 0x104]
call fcn.00457c30
test eax, eax
jne 0x457da4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 0x108]
mov esi, eax
push esi
push ecx
call fcn.0045a6e0
mov edx, dword [ebp - 0x110]
push eax
push esi
push str.ssrem_inet_ntop___failed_with_errno__d:__s
push edx
call fcn.00455a20
add esp, 0x18
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004815a9
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x108]
lea ebx, [eax + 0x100]
lea edi, [eax + 0xd0]
lea esi, [ebp - 0x84]
call fcn.00457c30
test eax, eax
jne 0x457e01
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov eax, dword [ebp - 0x108]
push esi
push eax
call fcn.0045a6e0
mov ecx, dword [ebp - 0x110]
push eax
push esi
push str.ssloc_inet_ntop___failed_with_errno__d:__s
push ecx
call fcn.00455a20
add esp, 0x18
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004815a9
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x108]
push esi
call fcn.00457bd0
mov ecx, dword [ebp - 4]
add esp, 4
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004815a9
mov esp, ebp
pop ebp
ret

Function at 0x457e30
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [edi]
mov eax, dword [esi + 0x314]
push 4
lea ecx, [ebp - 4]
push ecx
push 1
push 6
push edx
mov dword [ebp - 4], eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x457e76
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.0045a6e0
push eax
push str.Could_not_set_TCP_NODELAY:__s_n
push esi
call fcn.004559a0
add esp, 0x14
pop esi
mov esp, ebp
pop ebp
ret
push str.TCP_NODELAY_set_n
push esi
call fcn.004559a0
add esp, 8
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x457f10
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, dword [edi + 0x554]
test esi, esi
je 0x457f5b
mov eax, dword [edi + 0xc]
test eax, eax
je 0x457f5b
push 0x457ef0
lea ecx, [ebp - 8]
mov dword [ebp - 8], esi
mov dword [ebp - 4], 0
mov edx, dword [eax + 0x64]
push ecx
push edx
call fcn.0045f8c0
add esp, 0xc
cmp dword [ebp - 4], 0
jne 0x457f64
mov dword [edi + 0x554], 0
pop edi
or eax, 0xffffffff
pop esi
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x457f6d
mov dword [eax], esi
cmp dword [esi + 0x150], 0
mov edi, dword [esi + 0x130]
jne 0x457f5b
push 2
push 1
lea eax, [ebp + 0xb]
push eax
push edi
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
je 0x457f5b
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x458810
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
push ebx
xor ebx, ebx
lea ecx, [ebp - 0x10]
push ecx
mov ecx, dword [ebp + 8]
mov dword [eax], ebx
mov eax, dword [ebp + 0xc]
push edx
push eax
push ecx
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov dword [ebp - 8], eax
cmp eax, ebx
jne 0x4589a6
push edi
mov edi, dword [ebp - 0x10]
cmp edi, ebx
je 0x458988
push esi
cmp dword [edi + 4], 2
jne 0x45890c
cmp dword [edi + 0x18], ebx
je 0x45890c
mov eax, dword [edi + 0x10]
cmp eax, ebx
jbe 0x45890c
cmp eax, 0x10
jb 0x45890c
push 0x20
call dword [section..data]
mov esi, eax
add esp, 4
cmp esi, ebx
je 0x458919
mov edx, dword [edi]
mov dword [esi], edx
mov eax, dword [edi + 4]
mov dword [esi + 4], eax
mov ecx, dword [edi + 8]
mov dword [esi + 8], ecx
mov edx, dword [edi + 0xc]
push 0x10
mov dword [esi + 0xc], edx
mov dword [esi + 0x10], 0x10
mov dword [esi + 0x18], ebx
mov dword [esi + 0x14], ebx
mov dword [esi + 0x1c], ebx
call dword [section..data]
add esp, 4
mov dword [esi + 0x18], eax
cmp eax, ebx
je 0x458922
mov ecx, dword [edi + 0x18]
mov edx, dword [ecx]
mov dword [eax], edx
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov edx, dword [ecx + 8]
mov dword [eax + 8], edx
mov ecx, dword [ecx + 0xc]
mov dword [eax + 0xc], ecx
mov eax, dword [edi + 0x14]
cmp eax, ebx
je 0x4588f7
push eax
call dword [0x51e00c]
add esp, 4
mov dword [esi + 0x14], eax
cmp eax, ebx
je 0x458935
cmp dword [ebp - 4], ebx
jne 0x4588ff
mov dword [ebp - 4], esi
mov eax, dword [ebp - 0xc]
cmp eax, ebx
je 0x458909
mov dword [eax + 0x1c], esi
mov dword [ebp - 0xc], esi
mov edi, dword [edi + 0x1c]
cmp edi, ebx
jne 0x458852
jmp 0x458950
mov dword [ebp - 8], 8
jmp 0x458950
push esi
mov dword [ebp - 8], 8
call dword [0x51e004]
add esp, 4
jmp 0x458950
mov edx, dword [esi + 0x18]
push edx
mov dword [ebp - 8], 8
call dword [0x51e004]
push esi
call dword [0x51e004]
add esp, 8
mov eax, dword [ebp - 0x10]
pop esi
cmp eax, ebx
je 0x45895f
push eax
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
cmp dword [ebp - 8], ebx
je 0x458983
mov eax, dword [ebp - 4]
push eax
call fcn.004587c0
mov edx, dword [ebp + 0x14]
mov eax, dword [ebp - 8]
add esp, 4
mov ecx, ebx
pop edi
mov dword [ebp - 4], ebx
mov dword [edx], ecx
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 4], ebx
jne 0x45899a
push 0x2af9
mov dword [ebp - 8], 0x2af9
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 0x14]
mov eax, dword [ebp - 8]
mov dword [edx], ecx
pop edi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x45a060
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
push 0
push 0
push eax
push ecx
push 0
push 0
call fcn.0048446e
add esp, 0x18
test eax, eax
je 0x45a084
cmp eax, 0xffffffff
jne 0x45a086
xor eax, eax
pop ebp
ret
Function at 0x45eb30
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov al, byte [ebp + 8]
movsx ecx, al
add ecx, 0xffffff9f
cmp ecx, 0x19
ja case.default.0x45eb41
jmp dword [ecx*4 + 0x45ebb0]
mov al, 0x41
pop ebp
ret
mov al, 0x42
pop ebp
ret
mov al, 0x43
pop ebp
ret
mov al, 0x44
pop ebp
ret
mov al, 0x45
pop ebp
ret
mov al, 0x46
pop ebp
ret
mov al, 0x47
pop ebp
ret
mov al, 0x48
pop ebp
ret
mov al, 0x49
pop ebp
ret
mov al, 0x4a
pop ebp
ret
mov al, 0x4b
pop ebp
ret
mov al, 0x4c
pop ebp
ret
mov al, 0x4d
pop ebp
ret
mov al, 0x4e
pop ebp
ret
mov al, 0x4f
pop ebp
ret
mov al, 0x50
pop ebp
ret
mov al, 0x51
pop ebp
ret
mov al, 0x52
pop ebp
ret
mov al, 0x53
pop ebp
ret
mov al, 0x54
pop ebp
ret
mov al, 0x55
pop ebp
ret
mov al, 0x56
pop ebp
ret
mov al, 0x57
pop ebp
ret
mov al, 0x58
pop ebp
ret
mov al, 0x59
pop ebp
ret
mov al, 0x5a
pop ebp
ret
Function at 0x461f50
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x51e584]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push eax
call fcn.00486df2
add esp, 4
mov byte [ebp - 0x108], 0
test eax, eax
je 0x461fb4
push 0x104
lea ecx, [ebp - 0x108]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
cmp byte [ebp - 0x108], 0
je 0x461fb4
lea edx, [ebp - 0x108]
push edx
call dword [0x51e00c]
add esp, 4
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004815a9
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor ecx, ebp
xor eax, eax
call fcn.004815a9
mov esp, ebp
pop ebp
ret

Function at 0x461fd0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
pop ebp
jmp fcn.00461f50

Function at 0x465220
Capabilities:
Read file on windows

Disassembly:
push edi
mov edi, eax
mov eax, dword [esi]
cmp dword [eax + 4], 2
jne 0x465242
mov ecx, dword [esi + 0xc]
test ecx, ecx
jne 0x465236
xor eax, eax
pop edi
ret
mov eax, dword [eax + 8]
push eax
push edi
push 1
push ebx
call ecx
jmp 0x465272
cmp dword [esi + 8], 0
jne 0x465265
mov ecx, dword [eax + 8]
push 0x50d42c
push ecx
call fcn.004836e8
add esp, 8
mov dword [esi + 8], eax
test eax, eax
jne 0x465265
or eax, 0xffffffff
pop edi
ret
mov edx, dword [esi + 8]
push edx
push edi
push 1
push ebx
call fcn.00484f0e
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x465294
mov eax, dword [esi + 8]
test eax, eax
je 0x46528e
push eax
call fcn.00483bd9
add esp, 4
mov dword [esi + 8], edi
mov eax, dword [esi]
mov ecx, dword [eax]
mov dword [esi], ecx
mov eax, edi
pop edi
ret
Function at 0x4694d0
Capabilities:
Get number of processors

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5122b0
push 0x487a08
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
add esp, 0xffffffd0
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
mov dword [ebp - 0x1c], 0
mov dword [ebp - 4], 0
mov ecx, dword gs:[0x60]
mov dword [ebp - 0x24], ecx
mov ecx, dword gs:[0x64]
mov dword [ebp - 0x20], ecx
cmp dword [ebp - 0x20], 0
jne 0x4695be
mov eax, dword [ebp - 0x24]
mov ecx, dword [eax + 0x18]
mov dword [ebp - 0x30], ecx
mov edx, dword [eax + 0x1c]
mov dword [ebp - 0x2c], edx
mov eax, dword [ebp - 0x30]
xor ecx, ecx
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], ecx
mov edx, dword [ebp - 0x40]
cmp edx, dword [ebp - 0x30]
jne 0x4695be
mov eax, dword [ebp - 0x3c]
cmp eax, dword [ebp - 0x2c]
jne 0x4695be
mov ecx, dword [ebp - 0x30]
add ecx, 0x20
mov edx, dword [ebp - 0x2c]
adc edx, 0
mov dword [ebp - 0x34], ecx
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x38], eax
mov ecx, dword [ebp - 0x38]
mov edx, dword [ecx]
cmp edx, dword [ebp - 0x34]
je 0x4695be
mov eax, dword [ebp - 0x38]
cmp dword [eax + 4], 0
jne 0x4695be
mov ecx, dword [ebp - 0x38]
mov edx, dword [ecx]
mov dword [ebp - 0x38], edx
mov eax, dword [ebp - 0x38]
cmp dword [eax + 0x40], 0
je 0x4695bc
mov ecx, dword [ebp - 0x38]
cmp dword [ecx + 0x44], 0
jne 0x4695bc
mov edx, dword [ebp - 0x38]
mov eax, dword [edx + 0x40]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.0046e840
add esp, 8
movzx edx, al
test edx, edx
je 0x4695bc
mov eax, dword [ebp - 0x38]
cmp dword [eax + 0x24], 0
jne 0x4695ba
mov ecx, dword [ebp - 0x38]
mov edx, dword [ecx + 0x20]
mov dword [ebp - 0x1c], edx
jmp 0x4695be
jmp 0x469561
mov dword [ebp - 4], 0xffffffff
jmp 0x4695d7
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4696d0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
cmp dword [ebp + 0xc], 0
je 0x469764
push 2
lea eax, [ebp - 4]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00468770
add esp, 0x10
test eax, eax
je 0x469764
movzx eax, word [ebp - 4]
cmp eax, 0x5a4d
jne 0x469764
push 4
lea ecx, [ebp - 8]
push ecx
mov edx, dword [ebp + 0xc]
add edx, 0x3c
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.00468770
add esp, 0x10
test eax, eax
je 0x469764
push pe_nt_image_headers32
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
add edx, dword [ebp - 8]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.00468770
add esp, 0x10
test eax, eax
je 0x469764
mov ecx, dword [ebp + 0x10]
cmp dword [ecx], 0x4550
jne 0x469764
mov edx, dword [ebp + 0x10]
movzx eax, word [edx + 0x16]
and eax, 0x2000
jne 0x469764
mov dword [ebp - 0x10], 1
jmp 0x46976b
mov dword [ebp - 0x10], 0
mov cl, byte [ebp - 0x10]
mov byte [ebp - 9], cl
movzx edx, byte [ebp - 9]
test edx, edx
je 0x469784
mov eax, dword [ebp + 0x10]
add eax, 0x78
mov ecx, dword [ebp + 0x14]
mov dword [ecx], eax
mov al, byte [ebp - 9]
mov esp, ebp
pop ebp
ret
Function at 0x469790
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5122c0
push 0x487a08
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
add esp, 0xffffffe0
push ebx
push esi
push edi
push 0
push 0
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00469970
add esp, 0x10
mov byte [ebp - 0x19], al
movzx edx, byte [ebp - 0x19]
test edx, edx
jne 0x469950
push 0x10000
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x20], eax
mov dword [ebp - 4], 0
push 0x8000
mov eax, dword [ebp - 0x20]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x46981f
mov dword [ebp - 0x24], 0
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
push ecx
call fcn.00487b95
add esp, 8
mov eax, dword [ebp - 0x24]
jmp 0x469954
push 1
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00469970
add esp, 0x10
mov byte [ebp - 0x19], al
movzx edx, byte [ebp - 0x19]
test edx, edx
jne 0x469937
push 0x8000
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [0x524d38]
push ecx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x46987b
mov dword [ebp - 0x28], 0
push 0xffffffffffffffff
lea edx, [ebp - 0x10]
push edx
call fcn.00487b95
add esp, 8
mov eax, dword [ebp - 0x28]
jmp 0x469954
push 1
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00469970
add esp, 0x10
mov byte [ebp - 0x19], al
movzx eax, byte [ebp - 0x19]
test eax, eax
jne 0x469937
mov ecx, dword [ebp - 0x20]
push ecx
push 0x8000
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
jne 0x4698d0
mov dword [ebp - 0x2c], 0
push 0xffffffffffffffff
lea edx, [ebp - 0x10]
push edx
call fcn.00487b95
add esp, 8
mov eax, dword [ebp - 0x2c]
jmp 0x469954
push 0
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00469970
add esp, 0x10
mov byte [ebp - 0x19], al
movzx eax, byte [ebp - 0x19]
test eax, eax
jne 0x469937
push 0x8000
mov ecx, dword [ebp - 0x20]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
jne 0x46991e
mov dword [ebp - 0x30], 0
push 0xffffffffffffffff
lea edx, [ebp - 0x10]
push edx
call fcn.00487b95
add esp, 8
mov eax, dword [ebp - 0x30]
jmp 0x469954
push 0
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00469970
add esp, 0x10
mov byte [ebp - 0x19], al
mov dword [ebp - 4], 0xffffffff
call fcn.00469945
jmp 0x469950
movzx eax, byte [ebp - 0x19]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x469970
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
mov byte [ebp - 0x211], 0
movzx eax, byte [ebp + 0x14]
test eax, eax
je 0x46999a
cmp dword [ebp + 0x10], 0
je 0x46999a
mov ecx, dword [ebp + 0x10]
push ecx
call fcn.00469a20
add esp, 4
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp + 0x10]
push eax
lea ecx, [ebp - 0x210]
push ecx
call fcn.00469a80
add esp, 0xc
lea edx, [ebp - 0x210]
push edx
call fcn.0048772b
add esp, 4
cmp eax, 6
jbe 0x469a11
movzx eax, word [ebp - 0x20e]
cmp eax, 0x3a
je 0x4699e9
movzx ecx, word [ebp - 0x210]
cmp ecx, 0x5c
jne 0x469a11
movzx edx, word [ebp - 0x20e]
cmp edx, 0x5c
jne 0x469a11
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x469a11
lea ecx, [ebp - 0x210]
push ecx
mov ecx, dword [ebp + 0xc]
call fcn.004731c0
mov byte [ebp - 0x211], 1
mov al, byte [ebp - 0x211]
mov esp, ebp
pop ebp
ret
Function at 0x469bc0
Capabilities:
Modify service
Query service status
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov byte [ebp - 5], 0
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x469d7e
push 0xf01ff
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
je 0x469d61
mov dword [ebp - 0x14], 0
lea edx, [ebp - 0x14]
push edx
push 0
push 0
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfigW]
cmp dword [ebp - 0x14], 0
je 0x469d44
mov ecx, dword [ebp - 0x14]
shl ecx, 1
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x18], eax
lea edx, [ebp - 0x14]
push edx
mov eax, dword [ebp - 0x14]
shl eax, 1
push eax
mov ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfigW]
test eax, eax
je 0x469d27
lea eax, [ebp - 0x34]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
jne 0x469c73
mov dword [ebp - 0x30], 1
mov edx, dword [ebp - 0x18]
cmp dword [edx], 1
jne 0x469ca7
mov eax, dword [ebp - 0x18]
cmp dword [eax + 4], 1
jne 0x469ca7
mov ecx, dword [ebp - 0x18]
cmp dword [ecx + 8], 1
jne 0x469ca7
mov edx, dword [ebp - 0x18]
mov eax, dword [edx + 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.00469b60
add esp, 8
movzx edx, al
test edx, edx
jne 0x469cdc
mov eax, dword [ebp + 0x10]
push eax
push 0
push 0
push 0
push 0
push 0
mov ecx, dword [ebp + 0xc]
push ecx
push 1
push 1
push 1
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigW]
test eax, eax
je 0x469cd3
cmp dword [ebp - 0x30], 1
je 0x469cdc
mov dword [ebp - 0x38], 0
jmp 0x469ce3
mov dword [ebp - 0x38], 1
mov al, byte [ebp - 0x38]
mov byte [ebp - 5], al
movzx ecx, byte [ebp + 0x14]
test ecx, ecx
je 0x469d27
movzx edx, byte [ebp - 5]
test edx, edx
je 0x469d1a
cmp dword [ebp - 0x30], 4
je 0x469d11
push 0
push 0
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
je 0x469d1a
mov dword [ebp - 0x3c], 1
jmp 0x469d21
mov dword [ebp - 0x3c], 0
mov cl, byte [ebp - 0x3c]
mov byte [ebp - 5], cl
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov edx, dword [ebp - 0x18]
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov al, byte [ebp - 5]
mov esp, ebp
pop ebp
ret
Function at 0x469f20
Capabilities:
Delete service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov byte [ebp - 5], 0
call fcn.0046e2d0
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x469fb0
push 0xf01ff
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
je 0x469f93
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_DeleteService]
neg eax
sbb eax, eax
neg eax
mov byte [ebp - 5], al
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
movzx eax, byte [ebp - 5]
mov esp, ebp
pop ebp
ret 4

Function at 0x469fc0
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x21c
lea eax, [ebp - 4]
push eax
push 0xf003f
push 0
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x46a03f
mov dword [ebp - 0x21c], 0
push 0x104
lea eax, [ebp - 0x218]
push eax
mov ecx, dword [ebp - 0x21c]
push ecx
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
test eax, eax
jne 0x46a035
lea eax, [ebp - 0x218]
push eax
mov ecx, dword [ebp - 4]
push ecx
call fcn.00469fc0
add esp, 8
mov edx, dword [ebp - 0x21c]
add edx, 1
mov dword [ebp - 0x21c], edx
jmp 0x469ff0
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov esp, ebp
pop ebp
ret
Function at 0x46a510
Capabilities:
Hash data using sha1

Disassembly:
push ebp
mov ebp, esp
push 0xd0
push 0
mov eax, dword [ebp + 8]
push eax
call fcn.00485940
add esp, 0xc
mov ecx, dword [ebp + 8]
mov dword [ecx], 0x67452301
mov edx, dword [ebp + 8]
mov dword [edx + 4], 0xefcdab89
mov eax, dword [ebp + 8]
mov dword [eax + 8], 0x98badcfe
mov ecx, dword [ebp + 8]
mov dword [ecx + 0xc], 0x10325476
mov edx, dword [ebp + 8]
mov dword [edx + 0x10], 0xc3d2e1f0
pop ebp
ret

Function at 0x46d780
Capabilities:
Query service status
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov byte [ebp - 5], 0
call fcn.0046e2d0
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x46d7b6
push 0
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x46d856
push 0xf01ff
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
je 0x46d839
lea edx, [ebp - 0x2c]
push edx
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x46d7f4
cmp dword [ebp - 0x28], 4
je 0x46d80f
push 0
push 0
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
jne 0x46d80f
mov dword [ebp - 0x30], 0
jmp 0x46d816
mov dword [ebp - 0x30], 1
mov dl, byte [ebp - 0x30]
mov byte [ebp - 5], dl
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
movzx eax, byte [ebp - 5]
mov esp, ebp
pop ebp
ret 4