joyce8/EMBER2024-capa huggingface dataset:
Function at 0x454b5a
Capabilities:
Query environment variable

Disassembly:
mov eax, 0x4a992b
call fcn.004a8204
sub esp, 0x224
push ebx
push esi
push edi
xor esi, esi
push 0x206
lea eax, [ebp - 0x22e]
push esi
push eax
mov edi, ecx
mov dword [ebp - 0x18], esi
mov word [ebp - 0x230], si
call fcn.0047a1f0
xor ecx, ecx
add esp, 0xc
inc ecx
lea edx, [ebp - 0x14]
mov eax, edi
call fcn.00406859
push 0x4b9484
push eax
mov dword [ebp - 4], esi
call fcn.0040577e
mov ebx, eax
neg ebx
sbb bl, bl
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
inc bl
call fcn.00405bdc
test bl, bl
je 0x454d30
mov ebx, str.___
push ebx
call fcn.0047af28
mov esi, str.SystemRoot_
push esi
mov dword [ebp - 0x1c], eax
call fcn.0047af28
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
lea edx, [ebp - 0x10]
mov eax, edi
call fcn.00406859
push ebx
push eax
mov dword [ebp - 4], 1
call fcn.0040577e
mov ebx, eax
neg ebx
sbb bl, bl
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
inc bl
call fcn.00405bdc
test bl, bl
je 0x454c49
mov eax, dword [edi]
mov ecx, dword [eax - 0xc]
sub ecx, dword [ebp - 0x1c]
lea eax, [ebp - 0x10]
push eax
mov eax, edi
call fcn.00406809
mov dword [ebp - 4], 2
call fcn.0040520c
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
jmp 0x454cff
mov ecx, dword [ebp - 0x14]
lea edx, [ebp - 0x10]
mov eax, edi
call fcn.00406859
push esi
push eax
mov dword [ebp - 4], 3
call fcn.0040577e
mov ebx, eax
neg ebx
sbb bl, bl
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
inc bl
call fcn.00405bdc
test bl, bl
je 0x454d07
push 0x104
lea eax, [ebp - 0x230]
push eax
push str._SystemRoot_
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov eax, dword [edi]
mov ecx, dword [eax - 0xc]
sub ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x24]
push eax
inc ecx
mov eax, edi
call fcn.00406809
mov esi, eax
lea eax, [ebp - 0x230]
push eax
lea eax, [ebp - 0x28]
push eax
mov dword [ebp - 4], 4
call fcn.00405e57
lea ecx, [ebp - 0x20]
push esi
push ecx
mov ecx, eax
mov byte [ebp - 4], 5
call fcn.00406895
pop ecx
pop ecx
mov byte [ebp - 4], 6
call fcn.0040520c
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
call fcn.00405bdc
mov eax, dword [ebp - 0x28]
add eax, 0xfffffff0
call fcn.00405bdc
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x24]
add eax, 0xfffffff0
call fcn.00405bdc
mov eax, dword [edi]
mov ecx, dword [eax - 0xc]
cmp ecx, 3
jg 0x454d1a
mov esi, edi
call fcn.00405e17
jmp 0x454d37
cmp ecx, 1
jge 0x454d29
push 0x80070057
call fcn.00405d00
cmp word [eax + 2], 0x3a
jne 0x454d11
mov dword [ebp - 0x18], 1
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x18]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x454d49
Capabilities:
Terminate process

Disassembly:
push esi
push dword [esp + 8]
push 0
push 1
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x454d73
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
inc eax
pop esi
ret
xor eax, eax
pop esi
ret
Function at 0x4559c2
Capabilities:
Encode data using xor

Disassembly:
xor ecx, ecx
cmp dword [esp + 8], ecx
jle 0x4559da
mov eax, dword [esp + 4]
add eax, ecx
xor byte [eax], 0x88
inc ecx
cmp ecx, dword [esp + 8]
jl 0x4559ca
ret 8

Function at 0x455ac7
Capabilities:
Write file on windows

Disassembly:
mov eax, 0x4aacb0
call fcn.004a8204
sub esp, 0x10
mov eax, dword [0x4db1bc]
or dword [ebp - 0x18], 0xffffffff
push ebx
push esi
mov esi, ecx
push edi
mov ecx, 0x4db1bc
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
xor edi, edi
mov dword [ebp - 4], edi
mov eax, dword [esi + 0x1c]
mov ecx, dword [esi + 0x14]
push eax
push ecx
push edi
call fcn.00453c1b
push edi
mov ebx, eax
call fcn.0047f0f4
add esp, 0x10
mov dword [ebp - 0x14], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
xor edx, edx
mov ecx, 0x3e8
div ecx
movzx eax, word [esi + 0x34]
push edx
push dword [ebp - 0x14]
push ebx
push eax
push dword [ebp + 8]
lea eax, [ebp - 0x10]
push str._s_d__x__x__x.ich
call fcn.00406b6d
mov ebx, dword [esi + 0x1c]
mov esi, dword [esi + 0x14]
add esp, 0x18
push edi
push edi
push 2
push edi
push 1
push 0x40000000
push dword [ebp - 0x10]
mov dword [ebp - 0x14], edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0x1c], eax
je 0x455b95
push edi
lea ecx, [ebp + 8]
push ecx
push ebx
push esi
push eax
mov dword [ebp + 8], edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x455b84
cmp dword [ebp + 8], ebx
jne 0x455b84
mov dword [ebp - 0x14], 1
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x14], edi
je 0x455b95
mov dword [ebp - 0x18], edi
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.00405bdc
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x18]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 4
Function at 0x4560ec
Capabilities:
Get common file path

Disassembly:
mov eax, 0x4abc84
call fcn.004a8204
sub esp, 0x214
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
xor ebx, ebx
push 0x206
mov dword [ebp - 4], ebx
lea eax, [ebp - 0x21e]
push ebx
mov dword [ebp - 0x18], ebx
push eax
mov word [ebp - 0x220], bx
call fcn.0047a1f0
add esp, 0xc
mov ecx, 0x4db1bc
call fcn.00405e9a
xor edi, edi
inc edi
push edi
push 0x23
lea eax, [ebp - 0x220]
push eax
mov dword [ebp - 4], ebx
push ebx
mov dword [ebp - 0x18], edi
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
cmp eax, ebx
lea eax, [ebp - 0x220]
jne 0x4561b8
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
cmp eax, ebx
je 0x456242
lea eax, [ebp - 0x220]
push eax
push esi
call fcn.00406072
lea eax, [ebp - 0x14]
push eax
mov ecx, edi
mov eax, esi
call fcn.00406809
mov dword [ebp - 4], edi
mov edi, 0x4b9484
push edi
push eax
call fcn.0040577e
test eax, eax
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x14]
setne byte [ebp - 0xd]
add eax, 0xfffffff0
call fcn.00405bdc
cmp byte [ebp - 0xd], bl
je 0x4561b1
push edi
push esi
call fcn.00406693
push str.All_UsersApplication_Data_
jmp 0x4561f9
push eax
push esi
call fcn.00406072
lea eax, [ebp - 0x14]
push eax
mov ecx, edi
mov eax, esi
call fcn.00406809
mov edi, 0x4b9484
push edi
push eax
mov dword [ebp - 4], 2
call fcn.0040577e
test eax, eax
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x14]
setne byte [ebp - 0xd]
add eax, 0xfffffff0
call fcn.00405bdc
cmp byte [ebp - 0xd], bl
je 0x4561ff
push edi
push esi
call fcn.00406693
call fcn.00406288
lea eax, [ebp - 0x14]
push eax
call fcn.00455735
mov dword [ebp - 4], 3
mov eax, dword [eax]
push dword [eax - 0xc]
push eax
mov eax, esi
call fcn.00406bf6
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.00405bdc
push str.kich_
push esi
call fcn.00406693
push dword [esi]
call fcn.0045ac5d
pop ecx
mov ecx, dword [ebp - 0xc]
pop edi
mov eax, esi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x45667d
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [ebp + 8]
mov eax, dword [eax]
xor ecx, ecx
cmp eax, ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 4], ecx
je 0x456718
push ebx
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea edx, [ebp - 4]
push edx
push ecx
lea edx, [ebp - 8]
push edx
push ecx
mov ebx, str.svrid
push ebx
push eax
call edi
cmp dword [ebp - 8], 1
je 0x4566bf
cmp dword [ebp - 8], 2
jne 0x456716
push esi
mov esi, dword [ebp + 0xc]
call fcn.00405e17
mov eax, dword [ebp - 4]
shr eax, 1
inc eax
push eax
call fcn.00405d18
mov esi, eax
lea eax, [ebp - 4]
push eax
push esi
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp + 8]
push 0
push ebx
push dword [eax]
call edi
test eax, eax
jne 0x456715
mov eax, dword [ebp - 4]
shr eax, 1
and word [esi + eax*2], 0
mov esi, dword [ebp + 0xc]
mov eax, dword [esi]
test eax, eax
je 0x456707
push eax
call fcn.0047af28
pop ecx
mov edx, esi
call fcn.00405cd4
mov dword [ebp - 0xc], 1
pop esi
pop edi
pop ebx
mov eax, dword [ebp - 0xc]
leave
ret 8
Function at 0x45671f
Capabilities:
Set registry value

Disassembly:
push edi
xor edi, edi
cmp dword [esi], edi
je 0x45674e
push dword [esp + 8]
call fcn.0047af28
pop ecx
lea eax, [eax + eax + 2]
push eax
push dword [esp + 0xc]
push 1
push edi
push str.svrid
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
jne 0x45674e
inc edi
mov eax, edi
pop edi
ret 4
Function at 0x45693b
Capabilities:
Read .ini file

Disassembly:
mov eax, 0x4ad180
call fcn.004a8204
sub esp, 0x1c
and dword [ebp - 0x14], 0
push esi
push edi
and dword [ebp - 4], 0
mov eax, dword [0x4db1bc]
mov edi, 0x4db1bc
mov ecx, edi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
lea eax, [ebx + 0x24]
push eax
push ebx
mov byte [ebp - 4], 1
call fcn.00456b32
lea eax, [ebx + 0x38]
push eax
push ebx
call fcn.00456c3c
lea eax, [ebp - 0x1c]
push eax
call fcn.004574bc
push dword [ebp - 0x1c]
push 0x3e8
push str.TryNo
push 0x4be4e4
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
mov esi, eax
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff0
call fcn.00405bdc
mov dword [ebx + 4], esi
call fcn.00456d46
mov dword [ebx + 8], eax
call fcn.00456f4f
mov dword [ebx + 0xc], eax
mov eax, dword [0x4db1bc]
mov ecx, edi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x1c]
push eax
mov byte [ebp - 4], 2
call fcn.0045652a
cmp eax, 1
pop ecx
jne 0x4569ee
lea edi, [ebx + 0x4c]
lea eax, [ebp - 0x1c]
call fcn.0040520c
call fcn.00456452
push eax
push 0x4b95c4
lea eax, [ebx + 0x50]
call fcn.00406b6d
xor eax, eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x24]
push eax
lea esi, [ebp - 0x18]
call fcn.00408f36
add esp, 0x10
test eax, eax
jne 0x456a2c
mov eax, esi
push eax
call fcn.004092f2
pop ecx
cmp eax, 1
jne 0x456a37
mov eax, dword [ebp - 0x18]
mov dword [ebx + 0x5c], eax
push 1
call fcn.00435bfa
call fcn.00435e5a
push eax
push reloc.OLEAUT32.dll_SysReAllocString
lea esi, [ebp - 0x14]
call fcn.004358fb
lea esi, [ebp - 0x10]
call fcn.00405e17
mov eax, esi
push eax
push 0x4be728
lea eax, [ebp - 0x14]
push eax
call fcn.004060a5
push dword [ebp - 0x10]
call fcn.0047af23
pop ecx
mov dword [ebx + 0x10], eax
call fcn.00405e17
mov eax, esi
push eax
push 0x4be730
lea eax, [ebp - 0x14]
push eax
call fcn.004060a5
push dword [ebp - 0x10]
call fcn.0047af23
pop ecx
mov dword [ebx + 0x14], eax
call fcn.00405e17
mov eax, esi
push eax
push 0x4be73c
lea eax, [ebp - 0x14]
push eax
call fcn.004060a5
push dword [ebp - 0x10]
call fcn.0047af23
pop ecx
mov dword [ebx + 0x18], eax
call fcn.00405e17
mov eax, esi
push eax
push 0x4be748
lea eax, [ebp - 0x14]
push eax
call fcn.004060a5
push dword [ebp - 0x10]
call fcn.0047af23
pop ecx
mov dword [ebx + 0x1c], eax
call fcn.00405e17
mov eax, esi
push eax
push 0x4be754
lea eax, [ebp - 0x14]
push eax
call fcn.004060a5
mov esi, dword [ebp - 0x10]
push esi
call fcn.0047af23
mov dword [ebx + 0x20], eax
mov eax, dword [ebp - 0x1c]
pop ecx
add eax, 0xfffffff0
call fcn.00405bdc
lea eax, [esi - 0x10]
call fcn.00405bdc
cmp dword [ebp - 0x14], 0
je 0x456b21
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 0xc]
xor eax, eax
pop edi
inc eax
mov dword fs:[0], ecx
pop esi
leave
ret
Function at 0x456d46
Capabilities:
Read .ini file

Disassembly:
mov eax, 0x4abc49
call fcn.004a8204
sub esp, 0xe0
mov eax, dword [0x4db1bc]
push ebx
push esi
push edi
mov esi, 0x4db1bc
xor edi, edi
mov ecx, esi
mov dword [ebp - 0x24], edi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x20], eax
mov dword [ebp - 4], edi
mov eax, dword [0x4db1bc]
mov ecx, esi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x1c], eax
push 0xc6
lea eax, [ebp - 0xea]
push edi
mov byte [ebp - 4], 1
push eax
mov word [ebp - 0xec], di
call fcn.0047a1f0
mov eax, dword [0x4db1bc]
add esp, 0xc
mov ecx, esi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], 2
mov eax, dword [0x4db1bc]
mov ecx, esi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x14]
push eax
mov byte [ebp - 4], 3
call fcn.004574bc
lea edi, [ebp - 0x1c]
mov byte [ebp - 4], 4
call fcn.0040520c
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.00405bdc
mov eax, edi
call fcn.0040524d
lea eax, [ebp - 0x14]
push eax
call fcn.00457547
lea edi, [ebp - 0x20]
mov byte [ebp - 4], 5
call fcn.0040520c
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.00405bdc
push dword [ebp - 0x1c]
mov ebx, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
push 0x64
lea eax, [ebp - 0xec]
push eax
mov esi, 0x4b9580
push esi
push str.Version
push str.Common
call ebx
test eax, eax
je 0x456f11
lea eax, [ebp - 0xec]
push eax
lea eax, [ebp - 0x10]
push eax
call fcn.00406072
lea eax, [ebp - 0x10]
call fcn.0040524d
mov eax, dword [ebp - 0x10]
mov ecx, dword [eax - 0xc]
lea eax, [ebp - 0x14]
push eax
push 2
pop edx
lea eax, [ebp - 0x10]
call fcn.0040678b
lea edi, [ebp - 0x18]
mov byte [ebp - 4], 6
call fcn.0040520c
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.00405bdc
push esi
push 0x4b957c
mov eax, edi
push eax
call fcn.00454d77
push esi
push 0x4be770
mov eax, edi
push eax
call fcn.00454d77
push dword [ebp - 0x20]
lea eax, [ebp - 0xec]
push 0x64
push eax
push esi
push str.version
push str.infos
call ebx
test eax, eax
je 0x456f11
lea eax, [ebp - 0xec]
push eax
lea eax, [ebp - 0x10]
push eax
call fcn.00406072
lea eax, [ebp - 0x14]
push eax
push 6
pop ecx
lea eax, [ebp - 0x10]
call fcn.00406809
mov byte [ebp - 4], 7
mov eax, dword [eax]
push dword [eax - 0xc]
push eax
mov eax, edi
call fcn.00406bf6
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.00405bdc
push dword [ebp - 0x18]
call fcn.0047af23
pop ecx
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.00405bdc
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
call fcn.00405bdc
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff0
call fcn.00405bdc
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
call fcn.00405bdc
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x24]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x4574bc
Capabilities:
Check if file exists

Disassembly:
mov eax, 0x4abba5
call fcn.004a8204
push ecx
push ecx
push esi
push edi
mov edi, dword [ebp + 8]
and dword [ebp - 4], 0
and dword [ebp - 0x14], 0
lea eax, [ebp - 0x10]
push eax
call fcn.004065ba
pop ecx
xor esi, esi
inc esi
lea eax, [ebp - 0x10]
mov dword [ebp - 4], esi
call fcn.0040524d
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.00405bf4
add eax, 0x10
mov dword [edi], eax
push str.data_baseconfig.dat
push edi
mov dword [ebp - 0x14], esi
call fcn.00406693
push dword [edi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x45752a
lea eax, [ebp - 0x10]
call fcn.0040520c
push str.ressrcchsuplive.svr
push edi
call fcn.00406693
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.00405bdc
mov ecx, dword [ebp - 0xc]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret 4

Function at 0x457547
Capabilities:
Check if file exists

Disassembly:
mov eax, 0x4abba5
call fcn.004a8204
push ecx
push ecx
push esi
push edi
mov edi, dword [ebp + 8]
and dword [ebp - 4], 0
and dword [ebp - 0x14], 0
lea eax, [ebp - 0x10]
push eax
call fcn.004065ba
pop ecx
xor esi, esi
inc esi
lea eax, [ebp - 0x10]
mov dword [ebp - 4], esi
call fcn.0040524d
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.00405bf4
add eax, 0x10
mov dword [edi], eax
push str.data_version.ini
push edi
mov dword [ebp - 0x14], esi
call fcn.00406693
push dword [edi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x4575b5
lea eax, [ebp - 0x10]
call fcn.0040520c
push str.ressrcchs_version.ini
push edi
call fcn.00406693
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.00405bdc
mov ecx, dword [ebp - 0xc]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret 4

Function at 0x4575fb
Capabilities:
Set registry value

Disassembly:
push 4
lea eax, [esp + 0x10]
push eax
mov eax, dword [esp + 0xc]
push 4
push 0
push dword [esp + 0x18]
push dword [eax]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
ret 0xc
Function at 0x457699
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
xor ebx, ebx
push edi
xor eax, eax
cmp ecx, ebx
lea edi, [ebp - 0x13]
mov byte [ebp - 0x14], bl
mov dword [ebp - 4], ebx
stosd dword es:[edi], eax
mov dword [ebp - 0xc], ebx
je 0x457775
cmp word [ecx], bx
je 0x457775
push ebx
push 0x80
push 3
push ebx
push 1
push SysReAllocString
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
mov dword [ebp - 8], edi
je 0x457775
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, ebx
jbe 0x45776b
push ebx
lea eax, [ebp - 0xc]
push eax
push 4
lea eax, [ebp - 0x14]
push eax
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
call edi
test eax, eax
je 0x45776b
lea ecx, [ebp - 0x14]
call fcn.004577b1
test eax, eax
je 0x45776b
add esi, 0xfffffffc
lea eax, [esi + 1]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x45776b
mov eax, dword [ebp + 8]
push ebx
push ebx
push 4
push dword [ebp - 8]
mov dword [eax], esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebx
lea eax, [ebp - 0xc]
push eax
push esi
push dword [ebp - 4]
push dword [ebp - 8]
call edi
test eax, eax
je 0x45776b
mov edx, dword [ebp - 4]
call fcn.0045777c
test eax, eax
jge 0x45776b
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 4], ebx
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
mov eax, dword [ebp - 4]
pop edi
pop ebx
leave
ret

Function at 0x45777c
Capabilities:
Encode data using xor

Disassembly:
test edx, edx
je 0x4577ab
test esi, esi
jbe 0x4577ab
mov ecx, esi
shr ecx, 2
push 0
pop eax
je 0x45779a
xor dword [edx + eax*4], 0xd8d8d8d8
inc eax
cmp eax, ecx
jb 0x45778e
shl eax, 2
jmp 0x4577a4
xor byte [eax + edx], 0xd8
inc eax
cmp eax, esi
jb 0x45779f
xor eax, eax
ret
mov eax, 0x80004005
ret

Function at 0x4577d5
Capabilities:
Terminate thread

Disassembly:
mov eax, dword [esi]
test eax, eax
je 0x4577f3
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
and dword [esi], 0
or dword [esi + 0xc], 0xffffffff
ret
Function at 0x458685
Capabilities:
Create service
Modify service
Persist via windows service

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
push 2
xor esi, esi
push esi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
cmp eax, esi
mov dword [ebp - 4], eax
jne 0x4586a7
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop esi
leave
ret
push edi
push esi
push esi
push esi
push esi
push dword [ebp + 0x18]
push dword [ebp + 8]
push 1
push 2
push 0x10
push 0x32
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov edi, eax
cmp edi, esi
jne 0x458728
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 0x431
je 0x4586ee
call edi
mov esi, eax
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, esi
pop edi
jmp 0x4586a4
push 2
push dword [ebp + 0xc]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov edi, eax
cmp edi, esi
jne 0x45870a
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4586de
push dword [ebp + 0x14]
push esi
push esi
push esi
push esi
push dword [ebp + 0x18]
push dword [ebp + 8]
push 1
push 2
push 0x10
push edi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigW]
test eax, eax
je 0x458702
mov eax, dword [ebp + 0x14]
mov dword [ebp - 8], eax
lea eax, [ebp - 8]
push eax
push 1
push edi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2W]
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x4586e0

Function at 0x458744
Capabilities:
Delete service

Disassembly:
push edi
push 2
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov edi, eax
test edi, edi
jne 0x45875e
pop edi
jmp dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push esi
push 0x10000
push dword [esp + 0x14]
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov ebx, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov esi, eax
test esi, esi
jne 0x45878d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push edi
call ebx
mov eax, esi
pop esi
pop ebx
pop edi
ret
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
jne 0x4587b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ebx, eax
call edi
push esi
call edi
mov eax, ebx
jmp 0x458789
push esi
call ebx
xor esi, esi
jmp 0x458784
Function at 0x4587b7
Capabilities:
Query service status
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push esi
push 0x40000000
xor esi, esi
push esi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
cmp eax, esi
mov dword [ebp - 8], eax
jne 0x4587dc
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x458805
push ebx
push edi
push 0x14
push dword [ebp + 8]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov ebx, eax
cmp ebx, esi
jne 0x458808
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, esi
pop edi
pop ebx
pop esi
leave
ret
push 6
pop ecx
xor eax, eax
mov dword [ebp - 0x24], esi
lea edi, [ebp - 0x20]
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea eax, [ebp - 0x24]
push eax
push ebx
call edi
test eax, eax
je 0x458830
cmp dword [ebp - 0x20], 4
jne 0x458830
xor eax, eax
jmp 0x458803
push esi
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
jne 0x458857
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp - 8]
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov edi, eax
call esi
push ebx
call esi
mov eax, edi
jmp 0x458803
mov dword [ebp - 4], esi
cmp esi, 0xbb8
jge 0x458898
lea eax, [ebp - 0x24]
push eax
push ebx
call edi
test eax, eax
je 0x458886
cmp dword [ebp - 0x20], 1
je 0x458891
cmp dword [ebp - 0x20], 4
je 0x458898
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
add esi, 0x64
jmp 0x45885a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x458898
mov dword [ebp - 4], 0xe0000018
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov esi, dword [ebp - 4]
jmp 0x4587f8