joyce8/EMBER2024-capa huggingface dataset:
Function at 0x405200
Capabilities:
Persist via run registry key

Disassembly:
push 0xffffffffffffffff
push 0x433269
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push esi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x30]
mov dword fs:[0], eax
lea ecx, [esp + 0x18]
mov dword [esp + 0x38], 0
mov dword [esp + 8], 0
call fcn.0040b8a0
mov esi, dword [esp + 0x40]
push 0x43653f
mov ecx, esi
mov dword [esp + 0x3c], 1
call fcn.0040c060
push 0
push 1
push 1
push str.SoftwareMicrosoftWindowsCurrentVersionExplorerShell_Folders
push closesocket
lea ecx, [esp + 0x2c]
mov dword [esp + 0x1c], 1
call fcn.0040b910
test eax, eax
je 0x4052b8
push str.Common_Programs
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x20]
call fcn.0040b9d0
mov ecx, eax
mov byte [esp + 0x38], 2
call fcn.00419120
push eax
mov ecx, esi
call fcn.0040c3c0
lea ecx, [esp + 0xc]
mov byte [esp + 0x38], 1
call fcn.0040c0f0
lea ecx, [esp + 0x18]
call fcn.0040b9b0
lea ecx, [esp + 0x18]
mov byte [esp + 0x38], 0
call fcn.0040bd60
mov eax, esi
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x34
ret 4
Function at 0x405e40
Capabilities:
Get common file path

Disassembly:
sub esp, 0x10c
mov eax, dword [0x43fbfc]
xor eax, esp
mov dword [esp + 0x108], eax
push esi
mov esi, dword [esp + 0x114]
lea eax, [esp + 8]
push eax
push 0x103
mov dword [esp + 0xc], 0
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
cmp eax, 1
jae 0x405e87
push 0x43653f
mov ecx, esi
call fcn.0040c060
jmp 0x405e93
lea ecx, [esp + 8]
push ecx
mov ecx, esi
call fcn.0040c060
mov ecx, dword [esp + 0x10c]
mov eax, esi
pop esi
xor ecx, esp
call fcn.0041a1b8
add esp, 0x10c
ret 4

Function at 0x405eb0
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x54
push esi
push 0x44
lea eax, [esp + 0x18]
push 0
push eax
call fcn.0041a540
add esp, 0xc
xor eax, eax
lea ecx, [esp + 4]
push ecx
mov ecx, dword [esp + 0x60]
lea edx, [esp + 0x18]
push edx
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x68]
push eax
push 0
push 8
push 0
push 0
push 0
push ecx
push 0
mov dword [esp + 0x3c], 0x44
mov dword [esp + 0x68], 0x80
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov esi, eax
test esi, esi
jne 0x405f1a
pop esi
add esp, 0x54
ret 8
mov edx, dword [esp + 4]
push edi
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 8]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
call edi
mov ecx, dword [esp + 0xc]
push ecx
call edi
pop edi
mov eax, esi
pop esi
add esp, 0x54
ret 8

Function at 0x405f50
Capabilities:
Persist via run registry key

Disassembly:
push 0xffffffffffffffff
push 0x4333f9
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push esi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x30]
mov dword fs:[0], eax
lea ecx, [esp + 0x18]
mov dword [esp + 0x38], 0
mov dword [esp + 8], 0
call fcn.0040b8a0
mov esi, dword [esp + 0x40]
push 0x43653f
mov ecx, esi
mov dword [esp + 0x3c], 1
call fcn.0040c060
push 0
push 1
push 1
push str.SoftwareMicrosoftWindowsCurrentVersionExplorerShell_Folders
push closesocket
lea ecx, [esp + 0x2c]
mov dword [esp + 0x1c], 1
call fcn.0040b910
test eax, eax
je 0x406008
push str.Common_Desktop
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x20]
call fcn.0040b9d0
mov ecx, eax
mov byte [esp + 0x38], 2
call fcn.00419120
push eax
mov ecx, esi
call fcn.0040c3c0
lea ecx, [esp + 0xc]
mov byte [esp + 0x38], 1
call fcn.0040c0f0
lea ecx, [esp + 0x18]
call fcn.0040b9b0
lea ecx, [esp + 0x18]
mov byte [esp + 0x38], 0
call fcn.0040bd60
mov eax, esi
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x34
ret 4
Function at 0x406030
Capabilities:
Persist via run registry key

Disassembly:
push 0xffffffffffffffff
push 0x433449
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push esi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x30]
mov dword fs:[0], eax
lea ecx, [esp + 0x18]
mov dword [esp + 0x38], 0
mov dword [esp + 8], 0
call fcn.0040b8a0
mov esi, dword [esp + 0x40]
push 0x43653f
mov ecx, esi
mov dword [esp + 0x3c], 1
call fcn.0040c060
push 0
push 1
push 1
push str.SoftwareMicrosoftWindowsCurrentVersionExplorerShell_Folders
push closesocket
lea ecx, [esp + 0x2c]
mov dword [esp + 0x1c], 1
call fcn.0040b910
test eax, eax
je 0x4060e8
push str.Desktop
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x20]
call fcn.0040b9d0
mov ecx, eax
mov byte [esp + 0x38], 2
call fcn.00419120
push eax
mov ecx, esi
call fcn.0040c3c0
lea ecx, [esp + 0xc]
mov byte [esp + 0x38], 1
call fcn.0040c0f0
lea ecx, [esp + 0x18]
call fcn.0040b9b0
lea ecx, [esp + 0x18]
mov byte [esp + 0x38], 0
call fcn.0040bd60
mov eax, esi
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop esi
add esp, 0x34
ret 4
Function at 0x406950
Capabilities:
Create process on windows

Disassembly:
mov eax, 0x1164
call fcn.0041a510
mov eax, dword [0x43fbfc]
xor eax, esp
mov dword [esp + 0x1160], eax
push ebx
push esi
push edi
mov edi, dword [esp + 0x1174]
xor ebx, ebx
push 0xfff
lea eax, [esp + 0x171]
push ebx
push eax
mov byte [esp + 0x178], bl
call fcn.0041a540
push 0x44
lea ecx, [esp + 0x38]
push ebx
push ecx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x2c], ebx
call fcn.0041a540
push str.COMSPEC
lea edx, [esp + 0x30]
push edx
lea eax, [esp + 0x2c]
push eax
mov dword [esp + 0x4c], 0x44
mov dword [esp + 0x78], 1
mov word [esp + 0x7c], bx
call fcn.0041ba95
add esp, 0x24
test eax, eax
push 0xfff
je 0x406a22
push str.CMD.EXE
lea ecx, [esp + 0x174]
push 0x1000
push ecx
call fcn.0041b13a
mov eax, str.CMD.EXE
add esp, 0x10
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
add eax, 1
cmp cl, bl
jne 0x406a00
sub eax, edx
cmp eax, 0xfff
jae 0x406a19
mov byte [esp + eax + 0x16c], bl
mov byte [esp + 0x116b], bl
jmp 0x406a70
mov eax, dword [esp + 0x10]
push eax
lea edx, [esp + 0x174]
push 0x1000
push edx
mov esi, eax
call fcn.0041b13a
mov eax, esi
add esp, 0x10
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
cmp cl, bl
jne 0x406a43
sub eax, edx
cmp eax, 0xfff
jae 0x406a5c
mov byte [esp + eax + 0x16c], bl
mov eax, dword [esp + 0xc]
push eax
mov byte [esp + 0x116f], bl
call fcn.0041b986
add esp, 4
push str.__c
lea ecx, [esp + 0x170]
push 0x1000
push ecx
call fcn.0041b848
add esp, 0xc
mov ecx, edi
call fcn.00419120
push eax
lea edx, [esp + 0x170]
push 0x1000
push edx
call fcn.0041b848
push 0x4369ec
lea eax, [esp + 0x17c]
push 0x1000
push eax
call fcn.0041b848
mov ecx, dword [esp + 0x1190]
push ecx
push 0x4369e8
lea edx, [esp + 0x8c]
push 0x4369e0
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [esp + 0x94]
push eax
lea ecx, [esp + 0x198]
push 0x1000
push ecx
call fcn.0041b848
add esp, 0x34
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x2c]
push eax
push ebx
push ebx
push 0x10
push ebx
push ebx
push ebx
lea ecx, [esp + 0x18c]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x406b24
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x406b61
mov edx, dword [esp + 0x18]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x10]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
jne 0x406b49
mov dword [esp + 0x10], ebx
mov edx, dword [esp + 0x1c]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edx
call esi
mov eax, dword [esp + 0x18]
push eax
call esi
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x116c]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0041a1b8
add esp, 0x1164
ret 8
Function at 0x406e70
Capabilities:
Persist via run registry key

Disassembly:
push 0xffffffffffffffff
push 0x4335c6
mov eax, dword fs:[0]
push eax
sub esp, 0x230
mov eax, dword [0x43fbfc]
xor eax, esp
mov dword [esp + 0x22c], eax
push esi
push edi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x23c]
mov dword fs:[0], eax
mov esi, ecx
call fcn.004052e0
cmp eax, 2
jne 0x406f50
lea ecx, [esp + 0x24]
call fcn.004095b0
push 0x104
lea eax, [esp + 0x34]
push 0
push eax
mov dword [esp + 0x250], 0
call fcn.0041a540
add esp, 0xc
call fcn.0040cc20
test eax, eax
lea ecx, [esi + 0xc8]
je 0x406f07
push str.n5agent64.exe
call fcn.00419120
push eax
push 0x436a8c
lea ecx, [esp + 0x3c]
push ecx
jmp 0x406f1c
push str.n5agent.exe
call fcn.00419120
push eax
push 0x436a8c
lea edx, [esp + 0x3c]
push edx
call fcn.004067c0
add esp, 0x10
lea eax, [esp + 0x30]
push eax
push str.N5Client_Agent
lea ecx, [esp + 0x2c]
call fcn.00409b40
lea ecx, [esp + 0x24]
mov dword [esp + 0x244], 0xffffffff
call fcn.004099d0
jmp 0x407019
lea ecx, [esp + 0xc]
call fcn.0040b8a0
push 0x104
lea ecx, [esp + 0x138]
push 0
push ecx
mov dword [esp + 0x250], 1
call fcn.0041a540
add esp, 0xc
lea edi, [esi + 0xc8]
push str.n5start.exe
mov ecx, edi
call fcn.00419120
push eax
lea edx, [esp + 0x13c]
push 0x436a8c
push edx
call fcn.004067c0
add esp, 0x10
mov ecx, esi
call fcn.00405370
test eax, eax
push 0
push 0
lea ecx, [esp + 0x14]
push 0
jne 0x406fbf
push str.SoftwareMicrosoftWindowsCurrentVersion_runservices
jmp 0x406fc4
push str.SoftwareMicrosoftWindowsCurrentVersion_run
push closesocket
call fcn.0040b910
lea eax, [esp + 0x134]
push eax
push str.NetClient5
lea ecx, [esp + 0x14]
call fcn.0040bb20
lea ecx, [esp + 0xc]
call fcn.0040b9b0
mov ecx, edi
call fcn.00419120
push eax
lea ecx, [esp + 0x138]
push ecx
call fcn.0040c9e0
add esp, 8
lea ecx, [esp + 0xc]
mov dword [esp + 0x244], 0xffffffff
call fcn.0040bd60
mov ecx, dword [esp + 0x23c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [esp + 0x22c]
xor ecx, esp
call fcn.0041a1b8
add esp, 0x23c
ret
Function at 0x4070b0
Capabilities:
Extract resource via kernel32 functions
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x433650
mov eax, dword fs:[0]
push eax
sub esp, 0x2c
push ebx
push ebp
push esi
push edi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x40]
mov dword fs:[0], eax
mov esi, ecx
lea ecx, [esp + 0x1c]
call fcn.0040c030
xor ebx, ebx
lea ecx, [esp + 0x28]
mov dword [esp + 0x48], ebx
call fcn.0040c030
mov ecx, esi
mov byte [esp + 0x48], 1
call fcn.00405370
test eax, eax
jne 0x407110
mov ecx, esi
call fcn.004053d0
test eax, eax
je 0x407203
lea eax, [esp + 0x34]
push ebx
push eax
call fcn.0040cd80
add esp, 8
mov ecx, eax
mov byte [esp + 0x48], 2
call fcn.00419120
push eax
lea ecx, [esp + 0x2c]
call fcn.0040c3c0
lea ecx, [esp + 0x34]
mov byte [esp + 0x48], 1
call fcn.0040c0f0
push str.cabinet.dll
lea ecx, [esp + 0x38]
push ecx
lea ecx, [esp + 0x30]
call fcn.0040c5e0
mov ecx, eax
mov byte [esp + 0x48], 3
call fcn.00419120
push eax
lea ecx, [esp + 0x20]
call fcn.0040c3c0
lea ecx, [esp + 0x34]
mov byte [esp + 0x48], 1
call fcn.0040c0f0
push ebx
sub esp, 0xc
lea edx, [esp + 0x2c]
mov ecx, esp
mov dword [esp + 0x24], esp
push edx
call fcn.0040c500
call fcn.0040d3d0
add esp, 0x10
cmp eax, 1
je 0x407203
push 0x436a94
push 0x68
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push ebx
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
lea ecx, [esp + 0x34]
mov edi, eax
call fcn.00419120
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x407203
push ebx
lea eax, [esp + 0x1c]
push eax
push ebp
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x28]
mov byte [esp + 0x48], bl
call fcn.0040c0f0
lea ecx, [esp + 0x1c]
mov dword [esp + 0x48], 0xffffffff
call fcn.0040c0f0
mov eax, 1
mov ecx, dword [esp + 0x40]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret
Function at 0x407240
Capabilities:
Extract resource via kernel32 functions
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x433690
mov eax, dword fs:[0]
push eax
sub esp, 0x2c
push ebx
push ebp
push esi
push edi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x40]
mov dword fs:[0], eax
mov esi, ecx
lea ecx, [esp + 0x1c]
call fcn.0040c030
xor ebx, ebx
lea ecx, [esp + 0x28]
mov dword [esp + 0x48], ebx
call fcn.0040c030
mov ecx, esi
mov byte [esp + 0x48], 1
call fcn.004053d0
test eax, eax
je 0x407388
lea eax, [esp + 0x34]
push ebx
push eax
call fcn.0040cd80
add esp, 8
mov ecx, eax
mov byte [esp + 0x48], 2
call fcn.00419120
push eax
lea ecx, [esp + 0x2c]
call fcn.0040c3c0
lea ecx, [esp + 0x34]
mov byte [esp + 0x48], 1
call fcn.0040c0f0
push str.psapi.dll
lea ecx, [esp + 0x38]
push ecx
lea ecx, [esp + 0x30]
call fcn.0040c5e0
mov ecx, eax
mov byte [esp + 0x48], 3
call fcn.00419120
push eax
lea ecx, [esp + 0x20]
call fcn.0040c3c0
lea ecx, [esp + 0x34]
mov byte [esp + 0x48], 1
call fcn.0040c0f0
push ebx
sub esp, 0xc
lea edx, [esp + 0x2c]
mov ecx, esp
mov dword [esp + 0x24], esp
push edx
call fcn.0040c500
call fcn.0040d3d0
add esp, 0x10
cmp eax, 1
je 0x407388
push 0x436aa8
push 0x69
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push ebx
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
lea ecx, [esp + 0x34]
mov edi, eax
call fcn.00419120
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x407388
push ebx
lea eax, [esp + 0x1c]
push eax
push ebp
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x28]
mov byte [esp + 0x48], bl
call fcn.0040c0f0
lea ecx, [esp + 0x1c]
mov dword [esp + 0x48], 0xffffffff
call fcn.0040c0f0
mov eax, 1
mov ecx, dword [esp + 0x40]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret
Function at 0x409480
Capabilities:
Create thread

Disassembly:
push ecx
lea eax, [esp]
push eax
push 0
push ecx
push 0x4093b0
push 0
push 0
call fcn.0041bc75
add esp, 0x18
test eax, eax
jne 0x40949f
pop ecx
ret
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
pop ecx
ret

Function at 0x409600
Capabilities:
Continue service
Query service status
Start service

Disassembly:
sub esp, 0x20
push esi
mov esi, ecx
mov eax, dword [esi + 8]
test eax, eax
jne 0x409612
pop esi
add esp, 0x20
ret
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea ecx, [esp + 0xc]
push ecx
push eax
mov dword [esp + 0x10], 0
call ebx
test eax, eax
je 0x4096a6
push ebp
mov ebp, dword [sym.imp.ADVAPI32.dll_StartServiceA]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x409640
mov eax, dword [esp + 0x18]
cmp eax, 1
jne 0x409659
mov edx, dword [esi + 8]
push 0
push 0
push edx
call ebp
test eax, eax
je 0x4096a4
jmp 0x40967a
cmp eax, 7
jne 0x409675
mov ecx, dword [esi + 8]
lea eax, [esp + 0x14]
push eax
push 3
push ecx
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x4096a4
jmp 0x40967a
cmp eax, 4
je 0x40969c
push 0x1f4
call edi
mov eax, dword [esi + 8]
lea edx, [esp + 0x14]
push edx
push eax
call ebx
test eax, eax
jne 0x409640
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 0x20
ret
mov dword [esp + 0x10], 1
pop edi
pop ebp
mov eax, dword [esp + 8]
pop ebx
pop esi
add esp, 0x20
ret

Function at 0x4096b0
Capabilities:
Delete service
Query service status

Disassembly:
sub esp, 0x1c
push esi
mov esi, ecx
mov eax, dword [esi + 8]
test eax, eax
je 0x409733
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea ecx, [esp + 8]
push ecx
push eax
call ebx
test eax, eax
je 0x409732
push ebp
mov ebp, dword [sym.imp.ADVAPI32.dll_ControlService]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov edi, edi
mov eax, 1
cmp dword [esp + 0x14], eax
je 0x40971f
lea edx, [esp + 0x10]
push edx
push eax
mov dword [esp + 0x1c], eax
mov eax, dword [esi + 8]
push eax
call ebp
test eax, eax
je 0x409730
push 0x1f4
call edi
mov edx, dword [esi + 8]
lea ecx, [esp + 0x10]
push ecx
push edx
call ebx
test eax, eax
jne 0x4096e0
pop edi
pop ebp
pop ebx
pop esi
add esp, 0x1c
ret 4
cmp dword [esp + 0x30], 0
je 0x409730
mov eax, dword [esi + 8]
push eax
call dword [sym.imp.ADVAPI32.dll_DeleteService]
pop edi
pop ebp
pop ebx
pop esi
add esp, 0x1c
ret 4
Function at 0x409780
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x433a78
mov eax, dword fs:[0]
push eax
sub esp, 0x58
push ebx
push ebp
push esi
push edi
mov eax, dword [0x43fbfc]
xor eax, esp
push eax
lea eax, [esp + 0x6c]
mov dword fs:[0], eax
lea ecx, [esp + 0x3c]
xor esi, esi
call fcn.0040b8a0
lea ecx, [esp + 0x24]
mov dword [esp + 0x74], esi
mov dword [esp + 0x14], 0xffffffff
call fcn.0040c030
lea ecx, [esp + 0x18]
mov byte [esp + 0x74], 1
call fcn.0040c030
lea ecx, [esp + 0x54]
mov byte [esp + 0x74], 2
call fcn.0040b8a0
mov ebp, dword [esp + 0x7c]
push esi
push esi
push esi
push str.SYSTEMCurrentControlSetHardware_Profiles
push closesocket
lea ecx, [esp + 0x50]
mov byte [esp + 0x88], 3
mov dword [ebp], esi
call fcn.0040b910
test eax, eax
je 0x40997d
lea ecx, [esp + 0x3c]
call fcn.0040bd20
mov edi, eax
push edi
push esi
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0x48]
call fcn.0040bc50
push 0x43653f
mov ecx, eax
mov byte [esp + 0x78], 4
mov esi, 1
call fcn.00419120
push eax
lea ecx, [esp + 0x2c]
call fcn.0040c3c0
mov ecx, eax
call fcn.0040c170
test eax, eax
lea ecx, [esp + 0x30]
setne bl
mov byte [esp + 0x74], 3
call fcn.0040c0f0
test bl, bl
je 0x409978
lea ecx, [ecx]
push str.Current
lea ecx, [esp + 0x28]
mov dword [esp + 0x18], 0xffffffff
call fcn.0040c170
test eax, eax
je 0x409928
push str.SYSTEMCurrentControlSetHardware_Profiles
lea ecx, [esp + 0x1c]
call fcn.0040c3c0
push 0x43a760
lea ecx, [esp + 0x1c]
call fcn.0040c770
lea ecx, [esp + 0x24]
push ecx
lea ecx, [esp + 0x1c]
call fcn.0040c730
push 0x43a760
lea ecx, [esp + 0x1c]
call fcn.0040c770
push str.SystemCurrentControlSetEnumROOTLEGACY_N5CLIENT_AGENT0000
lea ecx, [esp + 0x1c]
call fcn.0040c770
push 0
push 0
push 0
lea ecx, [esp + 0x24]
call fcn.00419120
push eax
push closesocket
lea ecx, [esp + 0x68]
call fcn.0040b910
lea edx, [esp + 0x14]
push edx
push str.CSConfigFlags
lea ecx, [esp + 0x5c]
call fcn.0040bb60
test eax, eax
je 0x409928
cmp dword [esp + 0x14], 0
je 0x409928
push 0
push str.CSConfigFlags
lea ecx, [esp + 0x5c]
call fcn.0040bc20
test eax, eax
je 0x409928
add dword [ebp], 1
push edi
push esi
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0x48]
call fcn.0040bc50
push 0x43653f
mov ecx, eax
mov byte [esp + 0x78], 4
add esi, 1
call fcn.00419120
push eax
lea ecx, [esp + 0x2c]
call fcn.0040c3c0
mov ecx, eax
call fcn.0040c170
test eax, eax
lea ecx, [esp + 0x30]
setne bl
mov byte [esp + 0x74], 3
call fcn.0040c0f0
test bl, bl
jne 0x409870
mov esi, 1
lea ecx, [esp + 0x54]
mov byte [esp + 0x74], 2
call fcn.0040bd60
lea ecx, [esp + 0x18]
mov byte [esp + 0x74], 1
call fcn.0040c0f0
lea ecx, [esp + 0x24]
mov byte [esp + 0x74], 0
call fcn.0040c0f0
lea ecx, [esp + 0x3c]
mov dword [esp + 0x74], 0xffffffff
call fcn.0040bd60
mov eax, esi
mov ecx, dword [esp + 0x6c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret 4
Function at 0x4099e0
Capabilities:
Create service
Persist via windows service

Disassembly:
push esi
push 0xf003f
push 0
push 0
mov esi, ecx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
test eax, eax
mov dword [esi + 4], eax
jne 0x4099fd
pop esi
ret 8
push edi
mov edi, dword [esp + 0xc]
push 0xf01ff
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
test eax, eax
mov dword [esi + 8], eax
jne 0x409a95
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x424
je 0x409a34
mov eax, dword [esi + 4]
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [esi + 4], 0
mov edx, dword [esp + 0x10]
mov eax, edx
push ebp
lea ebp, [eax + 1]
mov edi, edi
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x409a40
sub eax, ebp
cmp eax, 1
pop ebp
jb 0x409a8e
push 0
mov ecx, dword [esi + 4]
push 0
push 0
push 0
push 0
push edx
push 1
push 2
push 0x110
push 0xf01ff
push edi
push edi
push ecx
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
test eax, eax
mov dword [esi + 8], eax
jne 0x409acd
mov edx, dword [esi + 4]
push edx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [esi + 4], 0
pop edi
xor eax, eax
pop esi
ret 8
mov edi, dword [esp + 0x10]
mov eax, edi
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x409aa0
sub eax, edx
je 0x409acd
lea eax, [esp + 0x10]
push eax
mov ecx, esi
mov dword [esp + 0x14], 0
call fcn.00409780
push edi
mov ecx, esi
call fcn.00409ba0
test eax, eax
je 0x409a8e
pop edi
mov eax, 1
pop esi
ret 8

Function at 0x409ba0
Capabilities:
Modify service
Query service configuration

Disassembly:
mov eax, 0x1008
call fcn.0041a510
mov eax, dword [0x43fbfc]
xor eax, esp
mov dword [esp + 0x1004], eax
push esi
push edi
mov edi, dword [esp + 0x1014]
push 0x1000
lea eax, [esp + 0x10]
push 0
push eax
mov esi, ecx
mov dword [esp + 0x14], 0
call fcn.0041a540
mov eax, dword [esi + 8]
add esp, 0xc
lea ecx, [esp + 8]
push ecx
push 0x1000
lea edx, [esp + 0x14]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfigA]
test eax, eax
jne 0x409c1a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, esi
call fcn.00409740
push edi
push str.N5Client_Agent
mov ecx, esi
call fcn.00409ae0
xor eax, eax
jmp 0x409c7c
cmp dword [esp + 0x14], 1
jne 0x409c44
cmp dword [esp + 0xc], 0x110
jne 0x409c44
cmp dword [esp + 0x10], 2
jne 0x409c44
mov ecx, dword [esp + 0x18]
push edi
push ecx
call fcn.0041be2b
add esp, 8
test eax, eax
je 0x409c77
mov edx, dword [esp + 0x2c]
mov eax, dword [esi + 8]
push edx
push 0
push 0
push 0
push 0
push 0
push edi
push 1
push 2
push 0x110
push eax
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
mov esi, eax
test esi, esi
jne 0x409c73
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, esi
jmp 0x409c7c
mov eax, 1
mov ecx, dword [esp + 0x100c]
pop edi
pop esi
xor ecx, esp
call fcn.0041a1b8
add esp, 0x1008
ret 4
Function at 0x40a250
Capabilities:
Get common file path

Disassembly:
sub esp, 0x104
mov eax, dword [0x43fbfc]
xor eax, esp
mov dword [esp + 0x100], eax
push esi
push edi
push 0xff
lea eax, [esp + 0xc]
push eax
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push str.CABINET.dll
lea ecx, [esp + 0xc]
push 0x100
push ecx
mov byte [esp + eax + 0x14], 0
call fcn.0041b848
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
add esp, 0xc
lea edx, [esp + 8]
push edx
call edi
test eax, eax
mov dword [esi + 4], eax
jne 0x40a307
push 0xff
lea eax, [esp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push str.CABINET.dll
lea ecx, [esp + 0xc]
push 0x100
push ecx
mov byte [esp + eax + 0x14], 0
call fcn.0041b848
add esp, 0xc
lea edx, [esp + 8]
push edx
call edi
test eax, eax
mov dword [esi + 4], eax
jne 0x40a307
push 0x436fbc
call edi
test eax, eax
mov dword [esi + 4], eax
jne 0x40a307
pop edi
pop esi
mov ecx, dword [esp + 0x100]
xor ecx, esp
call fcn.0041a1b8
add esp, 0x104
ret
mov ecx, dword [esp + 0x108]
pop edi
pop esi
xor ecx, esp
mov eax, 1
call fcn.0041a1b8
add esp, 0x104
ret