joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40abf0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebx
push esi
push edi
push ebp
lea esp, [esp - 0x48]
mov dword [esp + 0x44], edx
mov dword [esp + 0x40], ecx
mov dword [esp + 0x3c], eax
mov edx, dword [eax + 0x3c]
mov ecx, dword [esp + 0x3c]
lea eax, [edx + ecx]
mov eax, dword [eax + 0x78]
mov edx, dword [esp + 0x3c]
lea esi, [eax + edx]
mov edi, esp
mov ecx, 0xa
rep movsd dword es:[edi], dword [esi]
mov eax, dword [esp + 0x1c]
add eax, dword [esp + 0x3c]
mov dword [esp + 0x38], eax
mov eax, dword [esp + 0x20]
add eax, dword [esp + 0x3c]
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x24]
add eax, dword [esp + 0x3c]
mov dword [esp + 0x2c], eax
mov byte [esp + 0x34], 0
call fcn.0040a8b0
mov dword [esp + 0x28], eax
call fcn.0040a8e0
mov ebp, eax
mov eax, dword [esp + 0x18]
sub eax, 1
mov edi, eax
mov esi, 0
cmp edi, esi
jb 0x40acfa
sub esi, 1
nop
add esi, 1
mov eax, esi
shl eax, 2
add eax, dword [esp + 0x30]
mov eax, dword [eax]
add eax, dword [esp + 0x3c]
mov ebx, eax
mov edx, ebx
mov eax, ebp
call fcn.0040ab40
test al, al
je 0x40acbc
mov eax, esi
shl eax, 1
add eax, dword [esp + 0x2c]
movzx eax, word [eax]
shl eax, 2
add eax, dword [esp + 0x38]
mov eax, dword [eax]
mov edx, dword [esp + 0x40]
mov dword [edx], eax
mov al, byte [esp + 0x34]
test al, al
jne 0x40acfa
mov byte [esp + 0x34], 1
mov edx, ebx
mov eax, dword [esp + 0x28]
call fcn.0040ab40
test al, al
je 0x40acf2
mov eax, esi
shl eax, 1
add eax, dword [esp + 0x2c]
movzx eax, word [eax]
shl eax, 2
add eax, dword [esp + 0x38]
mov eax, dword [eax]
mov edx, dword [esp + 0x44]
mov dword [edx], eax
mov al, byte [esp + 0x34]
test al, al
jne 0x40acfa
mov byte [esp + 0x34], 1
cmp edi, esi
ja 0x40ac74
lea esp, [esp + 0x48]
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x40b130
Capabilities:
Inspect section memory permissions

Disassembly:
push ebp
mov ebp, esp
lea esp, [esp - 0x7c]
push ebx
push esi
push edi
mov dword [ebp - 0x24], 1
mov dword [ebp - 0x20], 8
mov dword [ebp - 0x1c], 2
mov dword [ebp - 0x18], 4
mov dword [ebp - 0x14], 0x10
mov dword [ebp - 0x10], pe_nt_image_headers32
mov dword [ebp - 0xc], 0x20
mov dword [ebp - 8], 0x40
mov ecx, dword [eax + 0x30]
mov dword [ebp - 0x7c], 0
mov dword [ebp - 0x78], eax
mov edx, dword [eax + 0x30]
mov eax, dword [ecx + 0x3c]
lea eax, [edx + eax]
movzx edx, word [eax + 6]
add eax, 0xf8
mov dword [ebp - 0x74], eax
lea eax, [edx - 1]
mov dword [ebp - 0x70], eax
mov dword [ebp - 0x6c], 0
mov eax, dword [ebp - 0x70]
cmp eax, dword [ebp - 0x6c]
jb 0x40b2b5
sub dword [ebp - 0x6c], 1
lea esi, [esi]
add dword [ebp - 0x6c], 1
imul eax, dword [ebp - 0x6c], 0x28
mov edx, dword [ebp - 0x74]
lea esi, [eax + edx]
lea edi, [ebp - 0x4c]
mov ecx, 0xa
rep movsd dword es:[edi], dword [esi]
mov eax, dword [ebp - 0x44]
mov edx, dword [ebp - 0x7c]
or edx, eax
mov dword [ebp - 0x58], edx
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x50], eax
test dword [ebp - 0x50], 0xffffffff
je 0x40b2a9
mov ebx, dword [ebp - 0x28]
mov eax, ebx
and eax, 0x2000000
je 0x40b20c
push 0x4000
push dword [ebp - 0x50]
push dword [ebp - 0x58]
mov esi, dword [ebp - 0x78]
call dword [esi + 8]
jmp 0x40b2a9
mov eax, ebx
and eax, 0x20000000
je 0x40b21e
mov dword [ebp - 0x68], 1
jmp 0x40b225
mov dword [ebp - 0x68], 0
mov eax, ebx
and eax, 0x40000000
je 0x40b237
mov dword [ebp - 0x64], 1
jmp 0x40b23e
mov dword [ebp - 0x64], 0
mov eax, ebx
and eax, 0x80000000
je 0x40b250
mov dword [ebp - 0x60], 1
jmp 0x40b257
mov dword [ebp - 0x60], 0
mov eax, ebx
and eax, 0x4000000
je 0x40b269
mov dword [ebp - 0x5c], 1
jmp 0x40b270
mov dword [ebp - 0x5c], 0
mov eax, dword [ebp - 0x68]
shl eax, 4
lea eax, [ebp + eax - 0x24]
mov edx, dword [ebp - 0x64]
lea ecx, [eax + edx*8]
mov eax, dword [ebp - 0x60]
mov eax, dword [ecx + eax*4]
mov dword [ebp - 0x54], eax
cmp dword [ebp - 0x5c], 1
jne 0x40b296
or dword [ebp - 0x54], 0x200
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x54]
push dword [ebp - 0x50]
push dword [ebp - 0x58]
mov esi, dword [ebp - 0x78]
call dword [esi + 4]
mov eax, dword [ebp - 0x70]
cmp eax, dword [ebp - 0x6c]
ja 0x40b1b4
pop edi
pop esi
pop ebx
leave
ret
Function at 0x1181000
Capabilities:
Accept command line arguments
Create process on windows
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x98
mov eax, dword [section..data]
xor eax, esp
mov dword [esp + 0x94], eax
push esi
push edi
mov edi, dword [ebp + 8]
lea eax, [esp + 0x34]
push eax
mov dword [esp + 0x18], edi
mov dword [esp + 0x38], 0
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov esi, eax
test esi, esi
je 0x11810bd
cmp dword [esp + 0x34], 2
jne 0x11810b6
push 0x40
lea eax, [esp + 0x40]
mov dword [esp + 0x3c], 0x44
push 0
push eax
call fcn.011821b0
add esp, 0xc
xor edi, edi
push dword [esi + 4]
call fcn.01184936
add esp, 4
test eax, eax
jle 0x11810b2
lea eax, [esp + 0x80]
xorps xmm0, xmm0
push eax
lea eax, [esp + 0x3c]
movaps xmmword [esp + 0x84], xmm0
push eax
push 0
push 0
push 0
push 1
push 0
push 0
push dword [esi]
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
push dword [esi + 4]
inc edi
call fcn.01184936
add esp, 4
cmp edi, eax
jl 0x1181074
mov edi, dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov esi, dword [sym.imp.USER32.dll_LoadStringW]
push 0x64
push 0x11964d0
push 0x67
push edi
call esi
push 0x64
push 0x1196408
push 0x6d
push edi
call esi
mov esi, dword [sym.imp.USER32.dll_LoadIconW]
push 0x6b
push edi
mov dword [esp + 0x40], 0x30
mov dword [esp + 0x44], 3
mov dword [esp + 0x48], 0x1181240
mov dword [esp + 0x4c], 0
mov dword [esp + 0x50], 0
mov dword [esp + 0x54], edi
call esi
push 0x7f00
push 0
mov dword [esp + 0x58], eax
call dword [sym.imp.USER32.dll_LoadCursorW]
push 0x6b
push dword [esp + 0x50]
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], 6
mov dword [esp + 0x64], 0x6d
mov dword [esp + 0x68], 0x1196408
call esi
mov dword [esp + 0x64], eax
lea eax, [esp + 0x38]
push eax
call dword [sym.imp.USER32.dll_RegisterClassExW]
push 0
push edi
push 0
push 0
push 0
push 0x80000000
push 0
push 0x80000000
push 0xcf0000
push 0x11964d0
push 0x1196408
push 0
call dword [sym.imp.USER32.dll_CreateWindowExW]
mov esi, eax
test esi, esi
jne 0x118119e
pop edi
pop esi
mov ecx, dword [esp + 0x94]
xor ecx, esp
call fcn.0118126a
mov esp, ebp
pop ebp
ret 0x10
push 7
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_UpdateWindow]
push 0x6d
push edi
call dword [sym.imp.USER32.dll_LoadAcceleratorsW]
mov esi, dword [sym.imp.USER32.dll_GetMessageW]
push 0
push 0
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x20]
push 0
push eax
call esi
test eax, eax
je 0x118121a
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
nop dword [eax + eax]
lea eax, [esp + 0x18]
push eax
push dword [esp + 0x18]
push dword [esp + 0x20]
call dword [sym.imp.USER32.dll_TranslateAcceleratorW]
test eax, eax
jne 0x1181209
lea eax, [esp + 0x18]
push eax
call edi
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageW]
push 0
push 0
push 0
lea eax, [esp + 0x24]
push eax
call esi
test eax, eax
jne 0x11811e0
mov ecx, dword [esp + 0x9c]
mov eax, dword [esp + 0x20]
pop edi
pop esi
xor ecx, esp
call fcn.0118126a
mov esp, ebp
pop ebp
ret 0x10
Function at 0x1181aa0
Capabilities:
Parse pe header

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

Function at 0x1186bd0
Capabilities:
Enumerate files on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x264
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x10]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x25c], ecx
cmp edx, edi
je 0x1186c1b
movzx eax, word [edx]
lea ecx, [ebp - 0x255]
push eax
call fcn.01186d6b
test al, al
jne 0x1186c15
sub edx, 2
cmp edx, edi
jne 0x1186bfb
mov ecx, dword [ebp - 0x25c]
movzx esi, word [edx]
cmp esi, 0x3a
jne 0x1186c3d
lea eax, [edi + 2]
cmp edx, eax
je 0x1186c3d
push ecx
xor ebx, ebx
push ebx
push ebx
push edi
call fcn.01186b1c
add esp, 0x10
jmp 0x1186d37
push esi
lea ecx, [ebp - 0x255]
call fcn.01186d6b
sub edx, edi
movzx eax, al
sar edx, 1
inc edx
neg eax
sbb eax, eax
xor ebx, ebx
push ebx
push ebx
and eax, edx
push ebx
mov dword [ebp - 0x260], eax
lea eax, [ebp - 0x254]
push eax
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileExW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x1186c80
push dword [ebp - 0x25c]
jmp 0x1186c2d
mov ebx, dword [ebp - 0x25c]
push 0x2e
mov eax, dword [ebx + 4]
sub eax, dword [ebx]
sar eax, 2
mov dword [ebp - 0x25c], eax
pop eax
cmp word [ebp - 0x228], ax
jne 0x1186cbd
cmp word [ebp - 0x226], 0
je 0x1186cde
cmp word [ebp - 0x226], ax
jne 0x1186cbd
cmp word [ebp - 0x224], 0
je 0x1186cde
push ebx
push dword [ebp - 0x260]
lea eax, [ebp - 0x228]
push edi
push eax
call fcn.01186b1c
add esp, 0x10
mov dword [ebp - 0x264], eax
test eax, eax
jne 0x1186d2a
lea eax, [ebp - 0x254]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
push 0x2e
test eax, eax
pop eax
jne 0x1186c97
mov eax, dword [ebx + 4]
mov edx, dword [ebx]
sub eax, edx
mov ecx, dword [ebp - 0x25c]
sar eax, 2
cmp ecx, eax
jne 0x1186d12
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
jmp 0x1186d37
push 0x118694c
sub eax, ecx
push 4
push eax
lea eax, [edx + ecx*4]
push eax
call fcn.01189870
add esp, 0x10
jmp 0x1186d07
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [ebp - 0x264]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0118126a
leave
ret

Function at 0x11887e8
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x11901f4
push 0x11901ec
push str.FlsAlloc
push 0x1f
call fcn.01188723
mov esi, eax
add esp, 0x10
test esi, esi
je 0x118881c
push dword [ebp + 8]
mov ecx, esi
call dword [0x118e150]
call esi
jmp 0x1188822
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4
Function at 0x1188866
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1190204
push 0x11901fc
push str.FlsGetValue
push 0x21
call fcn.01188723
mov esi, eax
add esp, 0x10
test esi, esi
je 0x118889d
push dword [ebp + 8]
mov ecx, esi
call dword [0x118e150]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x11888a5
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x119020c
push 0x1190204
push str.FlsSetValue
push 0x22
call fcn.01188723
mov esi, eax
add esp, 0x10
test esi, esi
je 0x11888df
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x118e150]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x118d5a0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x118d5cd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x118d5cd
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x402ac0
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x418428
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push ebx
push edi
mov eax, dword [0x426034]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x10], eax
xor ecx, ecx
mov dword [ebp - 0x1c], 7
push 0xffffffffffffffff
push ecx
lea edi, [eax + 0x18]
mov word [ebp - 0x30], cx
push edi
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x20], 0
call fcn.004014c0
lea ecx, [ebp - 0x30]
mov dword [ebp - 4], 0
call fcn.00404590
cmp dword [ebp - 0x1c], 8
lea eax, [ebp - 0x30]
cmovae eax, dword [ebp - 0x30]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
mov dword [ebp - 4], 0xffffffff
setne bl
cmp dword [ebp - 0x1c], 8
jb 0x402b4e
push dword [ebp - 0x30]
call dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete_void__]
add esp, 4
test bl, bl
je 0x402bae
xor eax, eax
mov dword [ebp - 0x1c], 7
push 0xffffffffffffffff
push eax
push edi
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x20], 0
mov word [ebp - 0x30], ax
call fcn.004014c0
lea ecx, [ebp - 0x30]
mov dword [ebp - 4], 1
call fcn.00404730
cmp dword [ebp - 0x1c], 8
lea edx, [ebp - 0x30]
push ecx
cmovae edx, dword [ebp - 0x30]
call fcn.00403660
add esp, 4
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x1c], 8
jb 0x402bae
push dword [ebp - 0x30]
call dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete_void__]
add esp, 4
sub esp, 0x18
xor eax, eax
mov ecx, esp
push 0xffffffffffffffff
push eax
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], 0
push edi
mov word [ecx], ax
call fcn.004014c0
call fcn.00403280
mov ecx, esp
mov dword [ebp - 0x14], esp
xor eax, eax
push 0xffffffffffffffff
push eax
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], 0
push edi
mov word [ecx], ax
call fcn.004014c0
sub esp, 0x18
mov dword [ebp - 4], 2
mov ecx, esp
xor eax, eax
push 0xffffffffffffffff
push eax
push dword [ebp - 0x10]
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], 0
mov word [ecx], ax
call fcn.004014c0
mov dword [ebp - 4], 0xffffffff
call fcn.00402180
add esp, 0x30
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403500
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4184e0
mov eax, dword fs:[0]
push eax
sub esp, 0x34
push ebx
push esi
push edi
mov eax, dword [0x426034]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, edx
mov dword [ebp - 0x28], ecx
lea ecx, [ebp + 8]
mov dword [ebp - 4], 0
call fcn.00404590
push 2
xor eax, eax
mov dword [ebp - 0x2c], 7
push 0x420e14
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
call fcn.00401870
mov byte [ebp - 4], 1
lea edx, [ebp + 8]
cmp dword [ebp + 0x1c], 8
mov dword [ebp - 0x10], 7
cmovae edx, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 0x14], 0
mov word [ebp - 0x24], ax
cmp word [edx], ax
jne 0x40358b
xor ecx, ecx
jmp 0x40359f
mov ecx, edx
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x403590
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x24]
call fcn.00401870
cmp dword [ebp - 0x2c], 8
lea ecx, [ebp - 0x40]
lea eax, [ebp - 0x24]
cmovae ecx, dword [ebp - 0x40]
cmp dword [ebp - 0x10], 8
push ecx
cmovae eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.MSVCR120.dll__wfopen]
mov esi, dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete_void__]
add esp, 8
cmp dword [ebp - 0x10], 8
mov edi, eax
jb 0x4035e0
push dword [ebp - 0x24]
call esi
add esp, 4
xor eax, eax
mov dword [ebp - 0x10], 7
cmp dword [ebp - 0x2c], 8
mov dword [ebp - 0x14], 0
mov word [ebp - 0x24], ax
jb 0x403602
push dword [ebp - 0x40]
call esi
add esp, 4
xor eax, eax
mov dword [ebp - 0x2c], 7
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
test edi, edi
je 0x403635
push edi
push 1
push ebx
push dword [ebp - 0x28]
call dword [sym.imp.MSVCR120.dll_fwrite]
push edi
call dword [sym.imp.MSVCR120.dll_fclose]
add esp, 0x14
mov bl, 1
jmp 0x403637
xor bl, bl
cmp dword [ebp + 0x1c], 8
jb 0x403645
push dword [ebp + 8]
call esi
add esp, 4
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403660
Capabilities:
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1024
call fcn.00418210
mov eax, dword [0x426034]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
xor eax, eax
mov esi, edx
push 0x7fe
push eax
mov word [ebp - 0x804], ax
xor bl, bl
lea eax, [ebp - 0x802]
push eax
call sub.MSVCR120.dll_memset
xor eax, eax
push 0x7fe
push eax
mov word [ebp - 0x1004], ax
lea eax, [ebp - 0x1002]
push eax
call sub.MSVCR120.dll_memset
lea ecx, [ebp - 0x804]
add esp, 0x18
sub ecx, esi
mov edi, edi
movzx eax, word [esi]
lea esi, [esi + 2]
mov word [ecx + esi - 2], ax
test ax, ax
jne 0x4036c0
xor eax, eax
movzx ecx, word [eax + 0x420e1c]
lea eax, [eax + 2]
mov word [ebp + eax - 0x1006], cx
test cx, cx
jne 0x4036d2
xorps xmm0, xmm0
mov dword [ebp - 0x1024], 0
movdqu xmmword [ebp - 0x1020], xmm0
mov eax, 0x14
mov word [ebp - 0x1008], cx
movq qword [ebp - 0x1010], xmm0
mov word [ebp - 0x1014], ax
lea eax, [ebp - 0x804]
mov dword [ebp - 0x101c], eax
lea eax, [ebp - 0x1004]
mov dword [ebp - 0x1018], eax
lea eax, [ebp - 0x1024]
push eax
mov dword [ebp - 0x1020], 3
call dword [sym.imp.SHELL32.dll_SHFileOperationW]
test eax, eax
movzx ecx, bl
mov edx, 1
cmove ecx, edx
mov al, cl
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00417832
mov esp, ebp
pop ebp
ret
Function at 0x4056d0
Capabilities:
Modify service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x418788
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x426034]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
sub esp, 0x18
mov dword [ebp - 4], 0
mov ecx, esp
xor eax, eax
push 0xffffffffffffffff
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], 0
push eax
mov word [ecx], ax
lea eax, [ebp + 8]
push eax
call fcn.004014c0
mov ecx, ebx
call fcn.004055d0
mov edi, eax
test edi, edi
jne 0x405750
push 0x41c38c
push str.WARN:__s__GetServiceConfig_FAIL_
push 1
push 0x53
push 0x41c3d4
push 0x41c3f8
call fcn.0040bd30
add esp, 0x18
xor esi, esi
test edi, edi
je 0x405760
cmp dword [edi + 4], 2
je 0x40580b
cmp dword [ebp + 0x1c], 8
lea eax, [ebp + 8]
push 2
cmovae eax, dword [ebp + 8]
push eax
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
test esi, esi
jne 0x4057a8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x41c41c
push str.WARN:__s__OpenService_FAIL__0x_x
push 1
push 0x63
push 0x41c464
push 0x41c488
call fcn.0040bd30
add esp, 0x1c
jmp 0x405873
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_ChangeServiceConfigW]
test eax, eax
jne 0x4057eb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.ERR:ChangeServiceConfig_failed___d__n
push 1
push 0x75
push 0x41c4d4
push 0x41c4f8
call fcn.0040bd30
add esp, 0x18
jmp 0x405868
push 2
push dword [edi + 4]
push str.Success_set_start_type_from__d_to__s
push 1
push 0x78
push 0x41c544
push 0x41c568
call fcn.0040bd30
add esp, 0x1c
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], 1
push eax
push 3
push esi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
test eax, eax
jne 0x40584a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.ERR:Fail_set_delay_auto_start__err0x_x
push 1
push 0x87
push 0x41c5b4
push 0x41c5d8
call fcn.0040bd30
add esp, 0x18
jmp 0x405868
push str.SUCCESS_set_delay_auto_start_
push 1
push 0x8b
push 0x41c61c
push str.CServiceObj::SetServiceAutoStart
call fcn.0040bd30
add esp, 0x14
test esi, esi
je 0x405873
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push edi
call dword [sym.imp.MSVCR120.dll_free]
add esp, 4
cmp dword [ebp + 0x1c], 8
jb 0x40588f
push dword [ebp + 8]
call dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
Function at 0x4058b0
Capabilities:
Create service
Modify service
Persist via windows service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4187c0
mov eax, dword fs:[0]
push eax
sub esp, 0x34
mov eax, dword [0x426034]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 4], 1
lea eax, [ebp + 8]
cmp dword [ebp + 0x1c], 8
cmovae eax, dword [ebp + 8]
push eax
push str.Create_Service_:__s...
push 1
push 0x9a
push 0x41c6d8
push 0x41c694
call fcn.0040c0c0
add esp, 0x18
lea esi, [ebp + 8]
cmp dword [ebp + 0x1c], 8
lea edx, [ebp + 8]
lea eax, [ebp + 0x20]
cmovae esi, dword [ebp + 8]
cmovae edx, dword [ebp + 8]
cmp dword [ebp + 0x34], 8
push 0
cmovae eax, dword [ebp + 0x20]
push 0
push 0
push 0
push 0
push eax
push 2
push 2
push 0x110
push 0xf01ff
push edx
push esi
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov esi, eax
test esi, esi
jne 0x405975
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.ERR:CreateService_fail_0x_x
push 1
push 0xbb
push 0x41c720
push 0x41c744
jmp 0x405a72
xorps xmm0, xmm0
mov dword [ebp - 0x40], 0x15180
movdqu xmmword [ebp - 0x3c], xmm0
lea eax, [ebp - 0x28]
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x40]
push eax
push 2
push esi
mov dword [ebp - 0x24], 0xea60
mov dword [ebp - 0x28], 1
mov dword [ebp - 0x1c], 0xea60
mov dword [ebp - 0x20], 1
mov dword [ebp - 0x14], 0xea60
mov dword [ebp - 0x18], 1
mov dword [ebp - 0x34], 3
mov dword [ebp - 0x38], 0
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2W]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x405a00
push str.ChangeConfig2:__SERVICE_CONFIG_FAILURE_ACTIONS__SUCCESS_
push 1
push 0xd6
push 0x41c794
push 0x41c7b8
call fcn.0040bd30
add esp, 0x14
jmp 0x405a21
call edi
push eax
push str.ERR:ChangeServiceConfig2_fail_0x_x
push 1
push 0xda
push 0x41c7f0
push 0x41c814
call fcn.0040bd30
add esp, 0x18
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 1
push eax
push 3
push esi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2W]
test eax, eax
je 0x405a59
push str.ChangeConfig2:__SERVICE_CONFIG_DELAYED_AUTO_START_INFO__SUCCESS_
push 1
push 0xe2
push 0x41c86c
push 0x41c890
call fcn.0040bd30
add esp, 0x14
jmp 0x405a7a
call edi
push eax
push str.ERR:ChangeServiceConfig2_Fail_set_delay_auto_start__0x_x
push 1
push 0xe6
push 0x41c8e0
push str.CServiceObj::Create
call fcn.0040bd30
add esp, 0x18
cmp dword [ebp + 0x1c], 8
mov edi, dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete_void__]
jb 0x405a8e
push dword [ebp + 8]
call edi
add esp, 4
xor eax, eax
mov dword [ebp + 0x1c], 7
cmp dword [ebp + 0x34], 8
mov dword [ebp + 0x18], 0
mov word [ebp + 8], ax
jb 0x405ab0
push dword [ebp + 0x20]
call edi
add esp, 4
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00417832
mov esp, ebp
pop ebp
ret 0x30
Function at 0x405ad0
Capabilities:
Query service status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x426034]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push ecx
push 0x24
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x28], 0
push ecx
xorps xmm0, xmm0
mov dword [ebp - 0x2c], 0
push 0
push eax
movdqu xmmword [ebp - 0x24], xmm0
movdqu xmmword [ebp - 0x14], xmm0
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
test eax, eax
je 0x405bac
mov eax, dword [ebp - 0x24]
cmp eax, 1
jne 0x405b28
mov ecx, str.SERVICE_STOPPED
jmp 0x405b74
cmp eax, 2
jne 0x405b34
mov ecx, str.SERVICE_START_PENDING
jmp 0x405b74
cmp eax, 3
jne 0x405b40
mov ecx, str.SERVICE_STOP_PENDING
jmp 0x405b74
cmp eax, 4
jne 0x405b4c
mov ecx, str.SERVICE_RUNNING
jmp 0x405b74
cmp eax, 5
jne 0x405b58
mov ecx, str.SERVICE_CONTINUE_PENDING
jmp 0x405b74
cmp eax, 6
jne 0x405b64
mov ecx, str.SERVICE_PAUSE_PENDING
jmp 0x405b74
cmp eax, 7
mov ecx, str.SERVICE_PAUSED
mov edx, str.UNKNOWN_SERVICE_STATE
cmovne ecx, edx
push ecx
push eax
push str.QueryServiceStatus:0x_x__s_
push 1
push 0xf6
push 0x41c950
push 0x41c998
call fcn.0040c0c0
add esp, 0x1c
cmp dword [ebp - 0x24], 4
jne 0x405bd1
mov al, 1
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00417832
mov esp, ebp
pop ebp
ret 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.ERR:QueryServiceStatusEx_fail_0x_x
push 1
push 0xfe
push 0x41c9f8
push str.CServiceObj::ServiceIsRunning
call fcn.0040bd30
add esp, 0x18
mov ecx, dword [ebp - 4]
xor al, al
xor ecx, ebp
call fcn.00417832
mov esp, ebp
pop ebp
ret 4