joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4df3a0
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x527240
mov eax, dword fs:[0]
push eax
sub esp, 0xb4
mov eax, dword [0x55e3f0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0xa8], ecx
mov eax, dword [ebp - 0xa8]
mov ecx, dword [ebp + 8]
mov dword [eax + 0x10], ecx
mov edx, dword [ebp - 0xa8]
mov eax, dword [edx + 0x10]
mov dword [eax + 0x590], 0
mov ecx, dword [ebp - 0xa8]
cmp dword [ecx + 4], 0
jne 0x4df4d9
mov dword [ebp - 0xc0], 8
mov dword [ebp - 0xbc], 0x800
lea edx, [ebp - 0xc0]
push edx
call dword [sym.imp.COMCTL32.dll_InitCommonControlsEx]
test eax, eax
je 0x4df493
lea eax, [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0xa8]
call fcn.004ded00
mov dword [ebp - 0xb0], 0x40030000
push 0
sub esp, 0x10
mov ecx, esp
mov edx, dword [ebp - 0x20]
mov dword [ecx], edx
mov eax, dword [ebp - 0x1c]
mov dword [ecx + 4], eax
mov edx, dword [ebp - 0x18]
mov dword [ecx + 8], edx
mov eax, dword [ebp - 0x14]
mov dword [ecx + 0xc], eax
push 0
mov ecx, dword [ebp - 0xb0]
push ecx
push 0
mov edx, dword [ebp - 0xa8]
mov eax, dword [edx + 0x10]
mov ecx, dword [ebp - 0xa8]
mov edx, dword [eax]
mov ecx, dword [ecx + 0x10]
mov eax, dword [edx + 0x1c]
call eax
mov ecx, eax
call fcn.00467570
push eax
mov ecx, dword [ebp - 0xa8]
call fcn.00470800
push 1
mov ecx, dword [ebp - 0xa8]
mov ecx, dword [ecx + 0x10]
call fcn.00466bd0
push eax
mov edx, dword [ebp - 0xa8]
mov eax, dword [edx + 0x10]
mov ecx, dword [ebp - 0xa8]
mov edx, dword [eax]
mov ecx, dword [ecx + 0x10]
mov eax, dword [edx + 0x1c]
call eax
mov ecx, eax
call fcn.00467020
mov ecx, dword [eax]
push ecx
push 0x30
mov edx, dword [ebp - 0xa8]
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.USER32.dll_SendMessageW]
lea ecx, [ebp - 0xa4]
push ecx
mov edx, dword [ebp - 0xa8]
mov eax, dword [edx + 0x10]
mov ecx, dword [ebp - 0xa8]
mov edx, dword [eax]
mov ecx, dword [ecx + 0x10]
mov eax, dword [edx + 0x28]
call eax
mov dword [ebp - 0xb4], eax
mov ecx, dword [ebp - 0xb4]
mov dword [ebp - 0xb8], ecx
mov dword [ebp - 4], 0
mov ecx, dword [ebp - 0xb8]
call fcn.00462fe0
mov byte [ebp - 0xa9], al
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xa4]
call fcn.00461fb0
movzx edx, byte [ebp - 0xa9]
test edx, edx
je 0x4df554
call fcn.004df120
mov ecx, dword [ebp - 0xa8]
mov edx, dword [ecx + 0x10]
mov dword [edx + 0x588], eax
mov eax, dword [ebp - 0xa8]
mov ecx, dword [eax + 0x10]
mov edx, dword [ecx + 0x588]
push edx
push 0
push 0x465
mov eax, dword [ebp - 0xa8]
mov ecx, dword [eax + 4]
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
push 5
mov edx, dword [ebp - 0xa8]
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov ecx, dword [ebp - 0xa8]
mov edx, dword [ecx + 4]
push edx
call dword [sym.imp.USER32.dll_SetFocus]
mov eax, dword [ebp - 0xa8]
mov byte [eax + 0x18], 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004f7a16
mov esp, ebp
pop ebp
ret 4
Function at 0x4df620
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov dword [ebp - 4], ecx
call dword [sym.imp.USER32.dll_GetFocus]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x4df665
call dword [sym.imp.USER32.dll_GetFocus]
mov ecx, dword [ebp - 4]
cmp eax, dword [ecx + 4]
jne 0x4df656
mov edx, dword [ebp + 0x14]
mov dword [edx], 1
xor eax, eax
jmp 0x4df6dd
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.USER32.dll_GetParent]
mov dword [ebp - 8], eax
jmp 0x4df632
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 4]
push edx
call dword [sym.imp.USER32.dll_DefWindowProcW]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x10]
cmp dword [ecx + 0x590], 0
jne 0x4df6cb
mov edx, dword [ebp - 4]
mov eax, dword [edx + 0x10]
add eax, 0x588
push eax
push 0
push 0x466
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 4]
push edx
call dword [sym.imp.USER32.dll_SendMessageW]
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x10]
mov dword [ecx + 0x590], 1
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x10]
call fcn.004df710
push 0
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 4]
push ecx
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret 0x10

Function at 0x4e6ee0
Capabilities:
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x527810
mov eax, dword fs:[0]
push eax
sub esp, 0x10
mov eax, dword [0x55e3f0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], ecx
mov ecx, dword [ebp - 0x10]
call fcn.004704b0
mov ecx, dword [ebp - 0x10]
add ecx, 0x10
call fcn.004e7070
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x10]
add eax, 0x18
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
mov dword [ecx], vtable.DuiLib::INotifyUI.0
mov edx, dword [ebp - 0x10]
add edx, 0x1c
mov dword [ebp - 0x18], edx
mov eax, dword [ebp - 0x18]
mov dword [eax], vtable.DuiLib::IDialogBuilderCallback.0
mov ecx, dword [ebp - 0x10]
mov dword [ecx], vtable.DuiLib::CMenuWnd.0
mov edx, dword [ebp - 0x10]
mov dword [edx + 0x10], vtable.DuiLib::CMenuWnd.1.0
mov eax, dword [ebp - 0x10]
mov dword [eax + 0x18], vtable.DuiLib::CMenuWnd.2.0
mov ecx, dword [ebp - 0x10]
mov dword [ecx + 0x1c], vtable.DuiLib::CMenuWnd.3.0
mov edx, dword [ebp - 0x10]
mov byte [edx + 0x20], 0
mov eax, dword [ebp - 0x10]
add eax, 0x2c
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
mov dword [ecx], 0x529990
mov ecx, dword [ebp - 0x10]
add ecx, 0x30
call fcn.00464450
mov edx, dword [ebp - 0x10]
mov dword [edx + 0x76c], 0
mov eax, dword [ebp - 0x10]
mov dword [eax + 0x770], 0
mov ecx, dword [ebp - 0x10]
mov dword [ecx + 0x774], 6
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret
Function at 0x4ea050
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
mov eax, dword [0x55e3f0]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x28], ecx
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp + 0x14]
mov dword [eax + 0x24], ecx
mov dword [eax + 0x28], edx
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp + 8]
mov dword [eax + 0x76c], ecx
mov edx, dword [ebp - 0x28]
mov dword [edx + 0x770], 0
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp + 0xc]
mov dword [eax + 0x2c], ecx
mov edx, dword [ebp - 0x28]
mov eax, dword [ebp + 0x20]
mov dword [edx + 0x774], eax
cmp dword [ebp + 8], 0
jne 0x4ea0de
call fcn.004e9c50
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp - 0x30]
mov eax, dword [edx]
mov ecx, dword [ebp - 0x30]
mov edx, dword [eax + 0xc]
call edx
cmp dword [ebp + 0x1c], 0
je 0x4ea0de
call fcn.004e9c50
mov dword [ebp - 0x34], eax
mov eax, dword [ebp + 0x1c]
push eax
mov ecx, dword [ebp - 0x34]
mov edx, dword [ecx]
mov ecx, dword [ebp - 0x34]
mov eax, dword [edx + 0x14]
call eax
cmp dword [ebp - 0x28], 0
je 0x4ea0ef
mov ecx, dword [ebp - 0x28]
add ecx, 0x10
mov dword [ebp - 0x38], ecx
jmp 0x4ea0f6
mov dword [ebp - 0x38], 0
call fcn.004e9c50
mov dword [ebp - 0x3c], eax
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov ecx, dword [ebp - 0x3c]
mov eax, dword [edx]
call eax
mov ecx, dword [ebp - 0x28]
cmp dword [ecx + 0x76c], 0
jne 0x4ea127
mov ecx, dword [ebp + 0x18]
call fcn.00467570
mov dword [ebp - 0x40], eax
jmp 0x4ea14a
mov edx, dword [ebp - 0x28]
mov eax, dword [edx + 0x76c]
mov ecx, dword [ebp - 0x28]
mov edx, dword [eax]
mov ecx, dword [ecx + 0x76c]
mov eax, dword [edx + 0x1c]
call eax
mov ecx, eax
call fcn.00467570
mov dword [ebp - 0x40], eax
lea ecx, [ebp - 0x24]
call fcn.00461d60
mov ecx, dword [eax]
mov dword [ebp - 0x14], ecx
mov edx, dword [eax + 4]
mov dword [ebp - 0x10], edx
mov ecx, dword [eax + 8]
mov dword [ebp - 0xc], ecx
mov edx, dword [eax + 0xc]
mov dword [ebp - 8], edx
push 0
sub esp, 0x10
mov eax, esp
mov ecx, dword [ebp - 0x14]
mov dword [eax], ecx
mov edx, dword [ebp - 0x10]
mov dword [eax + 4], edx
mov ecx, dword [ebp - 0xc]
mov dword [eax + 8], ecx
mov edx, dword [ebp - 8]
mov dword [eax + 0xc], edx
push 0x88
push connect
push 0
mov eax, dword [ebp - 0x40]
push eax
mov ecx, dword [ebp - 0x28]
call fcn.00470800
mov ecx, dword [ebp - 0x28]
mov edx, dword [ecx + 4]
mov dword [ebp - 0x2c], edx
mov eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.USER32.dll_GetParent]
test eax, eax
je 0x4ea1c5
mov ecx, dword [ebp - 0x2c]
push ecx
call dword [sym.imp.USER32.dll_GetParent]
mov dword [ebp - 0x2c], eax
jmp 0x4ea1a8
push 5
mov edx, dword [ebp - 0x28]
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
push 0
push 1
push 0x86
mov ecx, dword [ebp - 0x2c]
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004f7a16
mov esp, ebp
pop ebp
ret 0x1c
Function at 0x4f4380
Capabilities:
Get keyboard layout
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x21c
mov eax, dword [0x55e3f0]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x21c], ecx
mov dword [ebp - 0x218], 0
push 0
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push eax
push 0
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.USER32.dll_MapVirtualKeyExW]
mov dword [ebp - 0x210], eax
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x214], ecx
mov edx, dword [ebp - 0x214]
sub edx, 0x21
mov dword [ebp - 0x214], edx
cmp dword [ebp - 0x214], 0xd
ja case.0x4f43e5.8
mov eax, dword [ebp - 0x214]
jmp dword [eax*4 + 0x4f447c]
mov ecx, dword [ebp - 0x210]
or ecx, 0x100
mov dword [ebp - 0x210], ecx
cmp dword [ebp + 0x10], 0
je 0x4f4416
mov edx, dword [ebp - 0x210]
or edx, 0x1000000
mov dword [ebp - 0x210], edx
push 0x208
push 0
lea eax, [ebp - 0x20c]
push eax
call fcn.004fa2f0
add esp, 0xc
push 0x104
lea ecx, [ebp - 0x20c]
push ecx
mov edx, dword [ebp - 0x210]
shl edx, 0x10
push edx
call dword [sym.imp.USER32.dll_GetKeyNameTextW]
push 0xffffffffffffffff
lea eax, [ebp - 0x20c]
push eax
mov ecx, dword [ebp + 8]
call fcn.00461e10
mov ecx, dword [ebp - 0x218]
or ecx, 1
mov dword [ebp - 0x218], ecx
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004f7a16
mov esp, ebp
pop ebp
ret 0xc

Function at 0x4f81b9
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4f81f8
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4f81f8
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4f81f8
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x4f81f8
cmp dword [ecx + 0x74], 0xe
jbe 0x4f81f8
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x517f2a
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00517da0

Function at 0x51aea5
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0051ab22

Function at 0x522860
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x52288d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x52288d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x405c80
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x220
push ebx
push esi
mov ebx, ecx
mov ecx, 0x51008c
push edi
mov dword [ebp - 0x18], ebx
call fcn.004b532d
mov edi, dword [ebx + 4]
lea eax, [ebp - 0x14]
push eax
or edi, 0x2001f
mov dword [ebp - 0x10], 0
push edi
push 0
push dword [ebp + 8]
mov dword [ebp - 0xc], 0
push dword [ebx]
mov dword [ebp - 8], 0
mov dword [ebp - 0x14], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, eax
test esi, esi
jne 0x405d8d
mov eax, dword [ebp - 0x10]
xor esi, esi
test eax, eax
je 0x405cf0
push eax
call ebx
mov esi, eax
mov eax, dword [ebp - 0x14]
and edi, 0x300
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], edi
test esi, esi
jne 0x405d8d
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
lea ecx, [ebp - 0x20]
push ecx
push esi
push esi
push esi
lea ecx, [ebp - 4]
mov dword [ebp - 4], 0x100
push ecx
lea ecx, [ebp - 0x220]
push ecx
push esi
push eax
call edi
test eax, eax
jne 0x405d68
nop
lea eax, [ebp - 0x220]
push eax
lea ecx, [ebp - 0x10]
call fcn.00405c80
mov esi, eax
test esi, esi
jne 0x405d8d
lea eax, [ebp - 0x20]
mov dword [ebp - 4], 0x100
push eax
push esi
push esi
push esi
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x220]
push eax
push esi
push dword [ebp - 0x10]
call edi
test eax, eax
je 0x405d30
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x405d79
push eax
call ebx
mov dword [ebp - 0x10], 0
push dword [ebp + 8]
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0xc], 0
call fcn.00404750
mov esi, eax
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x405d97
push eax
call ebx
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x4071a0
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d82fd
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x4c
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
mov ecx, 0x5100a3
mov dword [ebp - 4], 0
call fcn.004b532d
lea eax, [ebp + 8]
mov byte [ebp - 4], 1
push eax
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x14], 1
push 0x4e00f4
push eax
call fcn.00403ed0
add esp, 0xc
push 0x4e00f0
push eax
lea eax, [ebp - 0x18]
mov byte [ebp - 4], 2
push eax
call fcn.00403e00
add esp, 0xc
push eax
lea ecx, [ebp + 8]
mov byte [ebp - 4], 3
call fcn.00403b80
mov edx, dword [ebp - 0x18]
or esi, 0xffffffff
mov byte [ebp - 4], 2
add edx, 0xfffffff0
mov eax, esi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x407236
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x1c]
mov eax, esi
mov byte [ebp - 4], 1
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x407254
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
cmp byte [ebp + 0x1c], 0
mov ecx, 0x440
mov eax, 0x40
mov dword [ebp - 0x58], 0x3c
cmovne eax, ecx
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x54], eax
mov ecx, 5
mov eax, dword [ebp + 8]
xorps xmm0, xmm0
mov dword [ebp - 0x48], eax
mov eax, dword [ebp + 0xc]
movlpd qword [ebp - 0x34], xmm0
movlpd qword [ebp - 0x2c], xmm0
movlpd qword [ebp - 0x24], xmm0
mov eax, dword [eax]
mov dword [ebp - 0x44], eax
xor eax, eax
cmp byte [ebp + 0x18], al
mov dword [ebp - 0x4c], 0
cmovne eax, ecx
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0x58]
push eax
mov dword [ebp - 0x38], 0
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
mov edi, dword [ebp + 0x14]
test edi, edi
je 0x4072d7
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_GetProcessId]
mov dword [edi], eax
cmp byte [ebp + 0x10], 0
je 0x4072f6
push dword [ebp + 0x20]
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov eax, dword [ebp + 8]
mov edi, dword [ebp - 0x14]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lock xadd dword [eax + 0xc], esi
dec esi
test esi, esi
jg 0x407318
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x407b20
Capabilities:
Get session information
Get session user name

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d845e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x20
mov ecx, 0x5100a3
mov dword [ebp - 4], 0
mov dword [ebp - 0x14], 0
call fcn.004b532d
call fcn.00405240
mov ecx, eax
test ecx, ecx
je 0x407c32
mov eax, dword [ecx]
push edi
call dword [eax + 0xc]
mov edi, dword [ebp + 8]
add eax, 0x10
mov dword [edi], eax
lea eax, [ebp - 0x18]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x14], 1
push eax
push 1
push 0
push 0
call sub.WTSAPI32.dll_WTSEnumerateSessionsW
test eax, eax
je 0x407c21
mov edx, dword [ebp - 0x18]
xor eax, eax
push esi
mov esi, dword [ebp - 0x1c]
test edx, edx
je 0x407bcc
lea ecx, [esi + 8]
nop dword [eax]
cmp dword [ecx], 0
je 0x407bbf
inc eax
add ecx, 0xc
cmp eax, edx
jb 0x407bb0
jmp 0x407bcc
lea eax, [eax + eax*2]
movq xmm0, qword [esi + eax*4]
movq qword [ebp - 0x2c], xmm0
push esi
call sub.WTSAPI32.dll_WTSFreeMemory
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x10]
push eax
push 5
push dword [ebp - 0x2c]
push 0
call sub.WTSAPI32.dll_WTSQuerySessionInformationW
test eax, eax
je 0x407c20
mov edx, dword [ebp - 0x10]
test edx, edx
jne 0x407bf5
xor ecx, ecx
jmp 0x407c0f
mov ecx, edx
lea esi, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x407c00
sub ecx, esi
sar ecx, 1
push ecx
push edx
mov ecx, edi
call fcn.00406280
push dword [ebp - 0x10]
call sub.WTSAPI32.dll_WTSFreeMemory
pop esi
mov ecx, dword [ebp - 0xc]
mov eax, edi
pop edi
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.004042d0
int3
Function at 0x4085a0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d851f
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10c
mov ecx, 0x5100a3
mov dword [ebp - 0x10], 0
call fcn.004b532d
mov dword [ebp - 4], 1
call fcn.00405240
mov ecx, eax
test ecx, ecx
je 0x408698
mov eax, dword [ecx]
push esi
call dword [eax + 0xc]
mov esi, dword [ebp + 8]
add eax, 0x10
push 0x104
push 0
mov dword [ebp - 0x10], 2
mov dword [esi], eax
lea eax, [ebp - 0x118]
push eax
call fcn.004b8400
add esp, 0xc
lea eax, [ebp - 0x118]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [ebp - 0x118]
mov ecx, esi
push eax
call fcn.00403c00
push 2
lea eax, [ebp - 0x14]
mov ecx, esi
push eax
call fcn.004057c0
push eax
mov ecx, esi
mov dword [ebp - 4], 2
call fcn.00403b80
mov edx, dword [ebp - 0x14]
or eax, 0xffffffff
mov byte [ebp - 4], 1
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40866b
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 7
push 0x4dfbbc
mov ecx, esi
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 1
call fcn.004040d0
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop esi
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.004042d0
int3
Function at 0x408850
Capabilities:
Check if file exists
Create service
Persist via windows service
Start service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d8555
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10
push edi
mov ecx, 0x5100a3
mov dword [ebp - 4], 1
call fcn.004b532d
push 0x4e0248
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0x18]
push eax
call fcn.00403e00
push 0x4e021c
push eax
lea eax, [ebp - 0x10]
mov byte [ebp - 4], 2
push eax
call fcn.00403e00
add esp, 0x18
mov edx, dword [ebp - 0x18]
or edi, 0xffffffff
mov byte [ebp - 4], 4
add edx, 0xfffffff0
mov eax, edi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4088c6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push ebx
push esi
push dword [ebp - 0x10]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40896b
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov ebx, eax
mov dword [ebp - 0x14], ebx
test ebx, ebx
je 0x40896b
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
push ecx
call fcn.004043f0
add esp, 4
lea esi, [eax + 0x10]
push 0
push 0
push 0
push 0
push 0
push dword [ebp - 0x10]
push 1
push 2
push pe_nt_image_headers32
push 0xf01ff
push esi
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov dword [ebp - 0x1c], eax
lea ebx, [esi - 0x10]
test eax, eax
jne 0x40893c
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x408957
push 0
push 0
push eax
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
push dword [ebp - 0x1c]
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push dword [ebp - 0x14]
call esi
mov eax, edi
lock xadd dword [ebx + 0xc], eax
dec eax
test eax, eax
jg 0x40896b
mov ecx, dword [ebx]
push ebx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x10]
mov eax, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 1
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x408989
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp + 8]
mov eax, edi
mov byte [ebp - 4], 0
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
pop esi
pop ebx
test eax, eax
jg 0x4089a9
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp + 0xc]
mov dword [ebp - 4], 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], edi
dec edi
test edi, edi
pop edi
jg 0x4089c9
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
Function at 0x408a80
Capabilities:
Get session user name

Disassembly:
push ebp
mov ebp, esp
mov eax, dword fs:[0]
mov ecx, 0x5100a3
push 0xffffffffffffffff
push 0x4d8585
push eax
mov dword fs:[0], esp
sub esp, 0x214
push esi
call fcn.004b532d
call dword [sym.imp.SHELL32.dll_IsUserAnAdmin]
test eax, eax
je 0x408bd3
lea eax, [ebp - 0x14]
push eax
call fcn.00407b20
push 0x208
lea eax, [ebp - 0x220]
mov dword [ebp - 4], 0
push 0
push eax
call fcn.004b8400
add esp, 0x10
mov dword [ebp - 0x18], 0x104
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
call fcn.00405240
mov ecx, eax
test ecx, ecx
je 0x408be4
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x220]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x10]
call fcn.00404300
test al, al
jne 0x408b4f
lea ecx, [ebp - 0x220]
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408b30
sub ecx, edx
lea eax, [ebp - 0x220]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x10]
call fcn.00406280
mov eax, dword [ebp - 0x14]
mov esi, dword [ebp - 0x10]
mov byte [ebp - 4], 0
cmp dword [eax - 0xc], 0
je 0x408b9a
cmp dword [esi - 0xc], 0
je 0x408b9a
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
call fcn.00403ce0
add esp, 8
test al, al
je 0x408b9a
lea ecx, [ebp - 0x10]
call fcn.00403a30
lea ecx, [ebp - 0x14]
call fcn.00403a30
mov al, 1
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
lea edx, [esi - 0x10]
or esi, 0xffffffff
mov eax, esi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x408bb4
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
lea edx, [eax - 0x10]
lock xadd dword [edx + 0xc], esi
dec esi
test esi, esi
jg 0x408bd3
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
xor al, al
pop esi
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.004042d0
int3