joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4021a0
Capabilities:
Identify system language via api

Disassembly:
push ecx
push esi
push edi
push 0
push 0xffff
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
mov esi, dword [esp + 0x1c]
mov edi, dword [sym.imp.KERNEL32.dll_FormatMessageW]
movzx ecx, ax
push ecx
push esi
push 0
push 0xb00
call edi
test eax, eax
jne 0x40221e
push eax
push 0xffff
lea edx, [esp + 0x10]
push edx
push eax
push esi
push eax
push 0xb00
call edi
test eax, eax
jne 0x40221e
push 0x40
push eax
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push esi
push str.system_error__lu
push 0xffffffffffffffff
push 0xffff
push eax
mov dword [esp + 0x1c], eax
call fcn.0041454f
add esp, 0x14
test eax, eax
jge 0x40221e
pop edi
xor eax, eax
pop esi
pop ecx
ret
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret

Function at 0x402230
Capabilities:
Access the windows event log

Disassembly:
sub esp, 0x40
push esi
push str.nssm
push 0
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceW]
mov esi, eax
test esi, esi
je 0x402296
mov ecx, dword [esp + 0x50]
xor eax, eax
test ecx, ecx
je 0x402268
lea edx, [esp + 0x50]
cmp eax, 0xf
jge 0x402268
add edx, 4
mov dword [esp + eax*4 + 4], ecx
mov ecx, dword [edx]
inc eax
test ecx, ecx
jne 0x402255
mov edx, dword [esp + 0x4c]
push 0
lea ecx, [esp + 8]
push ecx
push 0
push eax
push 0
push edx
mov dword [esp + eax*4 + 0x1c], 0
mov eax, dword [esp + 0x60]
push 0
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_ReportEventW]
push esi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
pop esi
add esp, 0x40
ret

Function at 0x402430
Capabilities:
Extract resource via kernel32 functions
Identify system language via api

Disassembly:
push edi
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
mov edi, dword [sym.imp.KERNEL32.dll_FindResourceExW]
movzx eax, ax
push eax
push esi
push 5
push 0
call edi
test eax, eax
jne 0x40246a
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x717
je 0x40245d
xor eax, eax
pop edi
ret
push 0
push esi
push 5
push 0
call edi
test eax, eax
je 0x402459
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x402459
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
push ecx
mov ecx, dword [esp + 0xc]
push edx
push ecx
push eax
push 0
call dword [sym.imp.USER32.dll_CreateDialogIndirectParamW]
pop edi
ret
Function at 0x402690
Capabilities:
Capture webcam image
Query environment variable
Set environment variable

Disassembly:
mov eax, 0x10408
call fcn.00414e50
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0x10404], eax
mov eax, dword [0x429630]
push ebp
mov ebp, dword [esp + 0x10410]
push esi
push edi
mov edi, dword [sym.imp.USER32.dll_GetDlgItem]
push 0x418
push eax
call edi
mov esi, dword [sym.imp.USER32.dll_SendMessageW]
push 0
push ebp
push 0x14e
push eax
call esi
mov ecx, dword [0x429630]
push 0x419
push ecx
call edi
push 0
push 0
mov edi, eax
push 0x14b
push edi
call esi
mov edx, dword [ebp*4 + section..data]
mov dword [esp + 0xc], edx
cmp ebp, 4
ja case.default.0x402706
jmp dword [ebp*4 + 0x4028f4]
push 0x4000026f
call fcn.004021a0
add esp, 4
push eax
push 0
push 0x14a
push edi
call esi
mov ebp, 0x4217fc
test ebx, ebx
je 0x402732
mov ebp, dword [esp + 0xc]
push 0x40000270
call fcn.004021a0
add esp, 4
push eax
push 1
push 0x14a
push edi
call esi
cmp ebx, 1
jne 0x4027c5
mov ebp, str.Post
jmp 0x4027c5
push 0x40000269
call fcn.004021a0
add esp, 4
push eax
push 0
push 0x14a
push edi
call esi
mov ebp, 0x4217fc
test ebx, ebx
je 0x40277b
mov ebp, dword [esp + 0xc]
push 0x4000026a
jmp 0x402737
push 0x4000026b
call fcn.004021a0
add esp, 4
push eax
push 0
push 0x14a
push edi
call esi
test ebx, ebx
jne case.default.0x402706
mov ebp, 0x4217fc
jmp 0x4027c5
push 0x4000026c
call fcn.004021a0
add esp, 4
push eax
push 0
push 0x14a
push edi
call esi
test ebx, ebx
je 0x40274f
mov ebp, dword [esp + 0xc]
push 0
push ebx
push 0x14e
push edi
call esi
mov eax, dword [esp + 0xc]
push ebp
push eax
push str.NSSM_HOOK__s__s
push 0xffffffffffffffff
lea ecx, [esp + 0x20]
push 0x200
push ecx
call fcn.0041454f
add esp, 0x18
cmp word [esp + 0x10], 0
pop edi
pop esi
pop ebp
je 0x4028dd
cmp byte [esp + 0x10410], 0
push 0x8000
je 0x4028a2
mov eax, dword [0x429630]
lea edx, [esp + 0x408]
push edx
push 0x41a
push eax
call dword [sym.imp.USER32.dll_GetDlgItemTextW]
lea ecx, [esp + 0x404]
push ecx
lea edx, [esp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ecx, dword [esp + 0x10404]
xor ecx, esp
call fcn.00414aec
add esp, 0x10408
ret
push 0x4000026d
call fcn.004021a0
add esp, 4
push eax
push 0
push 0x14a
push edi
call esi
mov ebp, str.Change
test ebx, ebx
je 0x402877
mov ebp, dword [esp + 0xc]
push 0x4000026e
call fcn.004021a0
add esp, 4
push eax
push 1
push 0x14a
push edi
call esi
cmp ebx, 1
jne 0x4027c5
mov ebp, str.Resume
jmp 0x4027c5
lea eax, [esp + 0x408]
push eax
lea ecx, [esp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x4028c3
xor edx, edx
mov word [esp + 0x404], dx
mov ecx, dword [0x429630]
lea eax, [esp + 0x404]
push eax
push 0x41a
push ecx
call dword [sym.imp.USER32.dll_SetDlgItemTextW]
mov ecx, dword [esp + 0x10404]
xor ecx, esp
call fcn.00414aec
add esp, 0x10408
ret
Function at 0x402910
Capabilities:
Query environment variable

Disassembly:
mov eax, 0x10404
call fcn.00414e50
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0x10400], eax
push edi
push esi
push str.NSSM_HOOK__s__s
push 0xffffffffffffffff
lea eax, [esp + 0x10]
push 0x200
push eax
call fcn.0041454f
add esp, 0x18
test eax, eax
jge 0x402961
mov eax, 1
mov ecx, dword [esp + 0x10400]
xor ecx, esp
call fcn.00414aec
add esp, 0x10404
ret
push 0x10000
lea ecx, [esp + 0x404]
push 0
push ecx
call fcn.00414b00
add esp, 0xc
push 0x8000
lea edx, [esp + 0x404]
push edx
lea eax, [esp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
lea ecx, [esp + 0x400]
push ecx
push edi
push esi
push ebx
call fcn.0040b050
mov ecx, dword [esp + 0x10410]
add esp, 0x10
neg eax
sbb eax, eax
xor ecx, esp
and eax, 2
call fcn.00414aec
add esp, 0x10404
ret
Function at 0x4059f0
Capabilities:
Set environment variable

Disassembly:
sub esp, 0x24
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x28]
push esi
test eax, eax
je 0x405a5e
test ecx, ecx
je 0x405a5e
mov edx, dword [eax]
mov esi, dword [eax + 4]
mov eax, edx
or eax, esi
je 0x405a5e
mov eax, dword [ecx]
mov ecx, dword [ecx + 4]
push ebx
mov ebx, eax
or ebx, ecx
pop ebx
je 0x405a5e
cmp ecx, esi
jb 0x405a5e
ja 0x405a2d
cmp eax, edx
jb 0x405a5e
push 0
sub eax, edx
push 0x2710
sbb ecx, esi
push ecx
push eax
call fcn.00414ee0
push edx
push eax
push str._llu
push 0xffffffffffffffff
lea ecx, [esp + 0x14]
push 0x10
push ecx
call fcn.0041454f
add esp, 0x18
lea edx, [esp + 4]
push edx
jmp 0x405a63
push 0x42198c
push edi
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ecx, dword [esp + 0x24]
pop esi
xor ecx, esp
call fcn.00414aec
add esp, 0x24
ret
Function at 0x406ea0
Capabilities:
Delete registry value

Disassembly:
sub esp, 0x40
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x48]
push esi
mov esi, dword [esp + 0x50]
push edi
mov edi, dword [esp + 0x4c]
push esi
push eax
push str._s_s
push 0xffffffffffffffff
lea eax, [esp + 0x18]
push 0x1d
push eax
call fcn.0041454f
add esp, 0x18
test eax, eax
jge 0x406f05
push 0
push str.delete_createfile_parameter__
push esi
push 0xc00003eb
push 1
call fcn.00402230
add esp, 0x14
pop edi
mov eax, 1
pop esi
mov ecx, dword [esp + 0x3c]
xor ecx, esp
call fcn.00414aec
add esp, 0x40
ret
lea ecx, [esp + 8]
push ecx
push edi
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov ecx, dword [esp + 0x44]
neg eax
pop edi
sbb eax, eax
pop esi
xor ecx, esp
inc eax
call fcn.00414aec
add esp, 0x40
ret

Function at 0x406f30
Capabilities:
Clear file content

Disassembly:
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
push esi
push edi
mov edi, dword [esp + 0xc]
push 0
push eax
mov eax, dword [esp + 0x18]
push ecx
push edx
push eax
push 2
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x406f85
mov ecx, dword [0x42965c]
mov edx, dword [0x429658]
push 2
push 0
push ecx
push edx
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x406f80
push esi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
pop edi
mov eax, esi
pop esi
ret
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
push edi
push 0xc0000419
push 1
call fcn.00402230
add esp, 0x14
pop edi
or eax, 0xffffffff
pop esi
ret
Function at 0x407cd0
Capabilities:
Create pipe
Create thread

Disassembly:
push esi
push edi
mov edi, dword [esp + 0x30]
mov esi, eax
mov dword [edi], 0
test ebx, ebx
je 0x407d0d
cmp dword [ebx], 0
jne 0x407d0d
test esi, esi
je 0x407d0d
cmp dword [esi], 0
jne 0x407d0d
push 0
push 0
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_CreatePipe]
test eax, eax
je 0x407d43
mov eax, dword [esi]
push 1
push 1
push eax
call dword [sym.imp.KERNEL32.dll_SetHandleInformation]
push 0x48
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
jne 0x407d6e
push eax
push str.create_logging_thread__
push str.logger
push 0xc00003eb
push 1
call fcn.00402230
add esp, 0x14
pop edi
xor eax, eax
pop esi
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
push eax
push ecx
push edx
push 0xc0000431
push 1
call fcn.00402230
add esp, 0x18
pop edi
xor eax, eax
pop esi
ret
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov dword [esi], eax
mov eax, dword [esp + 0x18]
mov dword [esi + 4], ecx
mov ecx, dword [esp + 0x1c]
mov dword [esi + 0xc], eax
mov eax, dword [esp + 0x20]
mov dword [esi + 8], edx
mov dword [esi + 0x10], ecx
mov edx, dword [ebx]
push edi
push 0
mov dword [esi + 0x14], edx
mov ecx, dword [eax]
mov edx, dword [esp + 0x2c]
mov eax, dword [esp + 0x30]
push esi
mov dword [esi + 0x18], ecx
mov cl, byte [esp + 0x44]
push 0x407850
mov dword [esi + 0x20], edx
mov edx, dword [esp + 0x44]
mov dword [esi + 0x24], eax
mov eax, dword [esp + 0x3c]
mov byte [esi + 0x30], cl
mov cl, byte [esp + 0x4c]
push 0
push 0
mov dword [esi + 0x28], edi
mov dword [esi + 0x38], 0
mov dword [esi + 0x3c], 0
mov dword [esi + 0x2c], edx
mov dword [esi + 0x44], eax
mov byte [esi + 0x40], cl
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edi, eax
test edi, edi
jne 0x407e21
push eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
push 0xc0000424
push 1
call fcn.00402230
add esp, 0x10
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, edi
pop edi
pop esi
ret

Function at 0x408710
Capabilities:
Get token membership

Disassembly:
sub esp, 0x10
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0xc], eax
push ebx
xor ebx, ebx
lea eax, [esp + 4]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x220
push 0x20
push 2
lea ecx, [esp + 0x30]
push ecx
mov byte [0x459661], bl
mov byte [esp + 0x34], bl
mov byte [esp + 0x35], bl
mov byte [esp + 0x36], bl
mov byte [esp + 0x37], bl
mov byte [esp + 0x38], bl
mov byte [esp + 0x39], 5
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x40877f
mov edx, dword [esp + 4]
push 0x459661
push edx
push ebx
call dword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov ecx, dword [esp + 0x10]
pop ebx
xor ecx, esp
call fcn.00414aec
add esp, 0x10
ret
Function at 0x408830
Capabilities:
Accept command line arguments
Create process on windows

Disassembly:
sub esp, 0x3c
push ebx
push esi
push eax
call fcn.0041439a
add eax, 0x40
push eax
call fcn.004022a0
push 0x3c
lea ecx, [esp + 0x14]
push 0
push ecx
call fcn.00414b00
add esp, 0x14
mov dword [esp + 8], 0x3c
mov dword [esp + 0x14], str.runas
call fcn.00408810
mov ebx, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push 0xfffe
push 8
mov dword [esp + 0x20], eax
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
jne 0x4088b3
push str.elevate__
push str.GetCommandLine__
push 0xc00001fa
call fcn.0041439a
add eax, 0x40
push eax
call fcn.004022a0
add esp, 0x10
lea eax, [esi + 0x6f]
pop esi
pop ebx
add esp, 0x3c
ret
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
push 0x421914
push 0xffffffffffffffff
push 0x7fff
push esi
call fcn.0041454f
mov edx, dword [esp + 0x5c]
mov eax, dword [edx]
add esp, 0x14
lea edx, [eax + 2]
jmp 0x4088e0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4088e0
sub eax, edx
sar eax, 1
cmp word [esi], 0x22
push edi
lea edi, [eax + 1]
jne 0x4088fc
add edi, 2
movzx eax, word [esi + edi*2]
push eax
call fcn.004155e4
add esp, 4
test eax, eax
je 0x408923
lea ecx, [ecx]
movzx ecx, word [esi + edi*2 + 2]
inc edi
push ecx
call fcn.004155e4
add esp, 4
test eax, eax
jne 0x408910
lea edx, [esi + edi*2]
lea eax, [esp + 0xc]
push eax
mov dword [esp + 0x24], edx
mov dword [esp + 0x2c], 5
xor edi, edi
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
jne 0x408946
lea edi, [eax + 0x64]
push esi
push 0
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x3c
ret
Function at 0x408e40
Capabilities:
Acquire debug privileges

Disassembly:
sub esp, 0x30
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push edi
lea eax, [esp + 8]
push eax
push 0
push 0x28
call esi
mov edi, dword [sym.imp.ADVAPI32.dll_OpenThreadToken]
push eax
call edi
test eax, eax
jne 0x408e86
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3f0
jne 0x408e86
push 2
call dword [sym.imp.ADVAPI32.dll_ImpersonateSelf]
lea ecx, [esp + 8]
push ecx
push 0
push 0x28
call esi
push eax
call edi
cmp dword [esp + 8], 0
je 0x408eb6
lea edx, [esp + 0x10]
push edx
push str.SeDebugPrivilege
push 0
mov dword [esp + 0x18], 0x10
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
jne 0x408ebf
mov eax, dword [esp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x30
ret
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov esi, dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov dword [esp + 0x2c], ecx
lea eax, [esp + 0xc]
push eax
lea ecx, [esp + 0x1c]
push ecx
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x38], edx
mov edx, dword [esp + 0x14]
push edx
lea eax, [esp + 0x34]
push eax
push 0
mov edi, 1
push ecx
mov dword [esp + 0x40], edi
mov dword [esp + 0x4c], 0
call esi
test eax, eax
jne 0x408f1b
mov edx, dword [esp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x30
ret
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
mov ecx, dword [esp + 0x14]
or dword [esp + 0x24], 2
push 0
push 0
push edx
mov dword [esp + 0x28], eax
lea eax, [esp + 0x24]
push eax
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x18]
push 0
push ecx
mov dword [esp + 0x30], edi
call esi
test eax, eax
je 0x408f07
mov eax, dword [esp + 8]
pop edi
pop esi
add esp, 0x30
ret
Function at 0x4092a0
Capabilities:
Enumerate threads

Disassembly:
sub esp, 0x1c
push ebp
push edi
xor edi, edi
push edi
push 4
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x4092e5
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
mov eax, dword [esp + 0x34]
mov ecx, dword [eax]
push ecx
push 0xc0000408
push 1
call fcn.00402230
add esp, 0x14
pop edi
xor eax, eax
pop ebp
add esp, 0x1c
ret
xor eax, eax
lea edx, [esp + 8]
push edx
mov dword [esp + 0xc], eax
push ebp
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x10], 0x1c
call sub.KERNEL32.dll_Thread32First
test eax, eax
jne 0x409350
push eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
mov eax, dword [esp + 0x34]
mov ecx, dword [eax]
push ecx
push 0xc0000409
push 1
call fcn.00402230
add esp, 0x14
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
xor eax, eax
pop ebp
add esp, 0x1c
ret
mov edx, dword [esp + 0x14]
push ebx
mov ebx, dword [sym.imp.USER32.dll_PostThreadMessageW]
push esi
mov esi, dword [esp + 0x34]
cmp edx, dword [esi + 0xc]
jne 0x409376
mov eax, dword [esi + 0x10]
mov ecx, dword [esp + 0x18]
push 0
push eax
push 0x12
push ecx
call ebx
mov edi, eax
lea edx, [esp + 0x10]
push edx
push ebp
call sub.KERNEL32.dll_Thread32Next
test eax, eax
je 0x4093ae
mov eax, dword [esp + 0x1c]
cmp eax, dword [esi + 0xc]
jne 0x40939f
mov ecx, dword [esi + 0x10]
mov edx, dword [esp + 0x18]
push 0
push ecx
push 0x12
push edx
call ebx
or edi, eax
lea eax, [esp + 0x10]
push eax
push ebp
call sub.KERNEL32.dll_Thread32Next
test eax, eax
jne 0x409385
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
cmp eax, 0x12
je 0x4093db
push 0
call ebx
push eax
call fcn.004020f0
mov ecx, dword [esi]
add esp, 4
push eax
push ecx
push 0xc0000409
push 1
call fcn.00402230
add esp, 0x14
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
pop ebx
mov eax, edi
pop edi
pop ebp
add esp, 0x1c
ret
Function at 0x4096a0
Capabilities:
Enumerate gui resources
Terminate process

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x4096b0
mov eax, 1
pop esi
ret
mov ecx, dword [esi + 4]
lea eax, [esp + 0xc]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
je 0x4096cd
cmp dword [esp + 0xc], 0x103
jne 0x4096a9
test byte [esi + 0x14], 1
je 0x4096e0
push esi
call fcn.00409560
add esp, 4
test eax, eax
je 0x4096a9
test byte [esi + 0x14], 2
je 0x409723
push esi
push 0x409240
call dword [sym.imp.USER32.dll_EnumWindows]
cmp dword [esi + 0x3c], 0
je 0x409723
mov edx, dword [esi + 0x1c]
mov eax, dword [esi]
mov ecx, dword [esi + 4]
push edx
mov edx, dword [esi + 0x28]
push str.kill_process
push eax
mov eax, dword [esi + 0x24]
push ecx
push edx
push eax
call fcn.0040ee40
add esp, 0x18
test eax, eax
je 0x4096a9
mov dword [esi + 0x3c], 0
test byte [esi + 0x14], 4
je 0x40975e
push esi
call fcn.004093f0
add esp, 4
test eax, eax
je 0x40975e
mov ecx, dword [esi + 0x20]
mov edx, dword [esi]
mov eax, dword [esi + 4]
push ecx
mov ecx, dword [esi + 0x28]
push str.kill_process
push edx
mov edx, dword [esi + 0x24]
push eax
push ecx
push edx
call fcn.0040ee40
add esp, 0x18
test eax, eax
je 0x4096a9
test byte [esi + 0x14], 8
je 0x409774
mov eax, dword [esi + 0x10]
mov ecx, dword [esi + 4]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
pop esi
ret
xor eax, eax
pop esi
ret
Function at 0x409c00
Capabilities:
Persist via windows service
Set registry value

Disassembly:
sub esp, 0x20c
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0x208], eax
push str.NSSM
push str.SYSTEMCurrentControlSetServicesEventLogApplication_s
push 0xffffffffffffffff
lea eax, [esp + 0x14]
push 0xff
push eax
call fcn.0041454f
add esp, 0x14
push 0
test eax, eax
jge 0x409c6b
push str.create_messages__
push str.eventlog_registry
push 0xc00003eb
push 1
call fcn.00402230
add esp, 0x14
mov eax, 1
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.00414aec
add esp, 0x20c
ret
lea ecx, [esp + 4]
push ecx
push 0
push 0x20006
push 0
push 0
push 0
lea edx, [esp + 0x24]
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
je 0x409cd1
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
lea eax, [esp + 0x10]
push eax
push 0xc00003f9
push 1
call fcn.00402230
add esp, 0x14
mov eax, 2
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.00414aec
add esp, 0x20c
ret
push esi
call fcn.00408800
mov ecx, eax
lea esi, [ecx + 2]
lea esp, [esp]
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x409ce0
mov edx, dword [esp + 4]
sub ecx, esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
sar ecx, 1
lea ecx, [ecx + ecx + 2]
push ecx
push eax
push 1
push 0
push str.EventMessageFile
push edx
call esi
mov ecx, dword [esp + 4]
push 4
lea eax, [esp + 0xc]
push eax
push 4
push 0
push str.TypesSupported
push ecx
mov dword [esp + 0x20], 7
call esi
mov ecx, dword [esp + 0x20c]
pop esi
xor ecx, esp
xor eax, eax
call fcn.00414aec
add esp, 0x20c
ret
Function at 0x409d90
Capabilities:
Set registry value

Disassembly:
sub esp, 0x20c
mov eax, dword [0x428930]
xor eax, esp
mov dword [esp + 0x208], eax
mov edx, dword [esp + 0x210]
push esi
push edi
mov edi, dword [esp + 0x21c]
push 1
mov eax, 0xff
lea ecx, [esp + 0x14]
mov esi, str.AppExit
call fcn.00409b10
add esp, 4
test eax, eax
jge 0x409e07
push 0
push str.create_exit_action__
push str.NSSM_REG_EXIT
push 0xc00003eb
push 1
call fcn.00402230
add esp, 0x14
pop edi
mov eax, 1
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.00414aec
add esp, 0x20c
ret
lea eax, [esp + 0xc]
push eax
lea ecx, [esp + 0xc]
push ecx
push 0
push 0x20006
push 0
push 0
push 0
lea edx, [esp + 0x2c]
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
je 0x409e74
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
lea eax, [esp + 0x18]
push eax
push 0xc00003f9
push 1
call fcn.00402230
add esp, 0x14
pop edi
mov eax, 2
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.00414aec
add esp, 0x20c
ret
cmp dword [esp + 0xc], 2
jne 0x409e8f
cmp byte [esp + 0x220], 0
jne 0x409e8f
mov ecx, dword [esp + 8]
push ecx
jmp 0x409f10
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x409e94
sub eax, edx
sar eax, 1
lea edx, [eax + eax + 2]
mov eax, dword [esp + 8]
push edx
push edi
push 1
push 0
push 0
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x409f0b
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004020f0
add esp, 4
push eax
push str.AppExit
push 0xc00003fb
push 1
call fcn.00402230
mov ecx, dword [esp + 0x1c]
add esp, 0x14
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, 3
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.00414aec
add esp, 0x20c
ret
mov edx, dword [esp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x210]
pop edi
pop esi
xor ecx, esp
xor eax, eax
call fcn.00414aec
add esp, 0x20c
ret