joyce8/EMBER2024-capa huggingface dataset:
Function at 0x41cd40
Capabilities:
Encode data using xor

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x41cd4f
xor eax, eax
pop esi
ret 0xc
mov eax, dword [0x473938]
test eax, eax
je 0x41cd5d
call fcn.0041cce0
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
cmp edx, 8
push ebx
not eax
jb 0x41ce5f
push edi
mov edi, edx
shr edi, 3
mov ecx, eax
xor ebx, ebx
mov bl, byte [esi]
and ecx, 0xff
xor ecx, ebx
mov ebx, eax
shr ebx, 8
mov eax, dword [ecx*4 + 0x4a39f0]
sub edx, 8
xor eax, ebx
inc esi
mov ecx, eax
xor ebx, ebx
mov bl, byte [esi]
and ecx, 0xff
xor ecx, ebx
xor ebx, ebx
mov bl, byte [esi + 1]
mov ecx, dword [ecx*4 + 0x4a39f0]
shr eax, 8
xor ecx, eax
inc esi
mov eax, ecx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [esi + 1]
mov eax, dword [eax*4 + 0x4a39f0]
shr ecx, 8
xor eax, ecx
inc esi
mov ecx, eax
and ecx, 0xff
xor ecx, ebx
xor ebx, ebx
mov bl, byte [esi + 1]
mov ecx, dword [ecx*4 + 0x4a39f0]
shr eax, 8
xor ecx, eax
inc esi
mov eax, ecx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [esi + 1]
mov eax, dword [eax*4 + 0x4a39f0]
shr ecx, 8
xor eax, ecx
inc esi
mov ecx, eax
and ecx, 0xff
xor ecx, ebx
xor ebx, ebx
mov bl, byte [esi + 1]
mov ecx, dword [ecx*4 + 0x4a39f0]
shr eax, 8
xor ecx, eax
inc esi
mov eax, ecx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [esi + 1]
mov eax, dword [eax*4 + 0x4a39f0]
shr ecx, 8
xor eax, ecx
inc esi
mov ecx, eax
and ecx, 0xff
xor ecx, ebx
shr eax, 8
mov ecx, dword [ecx*4 + 0x4a39f0]
xor eax, ecx
inc esi
dec edi
jne 0x41cd77
pop edi
test edx, edx
je 0x41ce81
mov ecx, eax
xor ebx, ebx
mov bl, byte [esi]
and ecx, 0xff
xor ecx, ebx
shr eax, 8
mov ecx, dword [ecx*4 + 0x4a39f0]
xor eax, ecx
inc esi
dec edx
jne 0x41ce63
pop ebx
pop esi
not eax
ret 0xc
Function at 0x42210b
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, ecx
mov dword [edi + 0x58], ebx
test ebx, 0xffff0000
jne 0x42212f
cmp dword [edi + 0x54], 0
jne 0x42212f
movzx eax, bx
mov dword [edi + 0x54], eax
call fcn.0042a359
mov esi, dword [eax + 0xc]
push 5
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push dword [ebp + 0xc]
mov ebx, eax
push ebx
mov ecx, edi
call fcn.004220cc
push ebx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_FreeResource]
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 8

Function at 0x428042
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
xor ebx, ebx
xor edi, edi
mov dword [ebp - 4], ecx
cmp dword [ebp + 8], ebx
je 0x428089
call fcn.0042a359
mov esi, dword [eax + 0xc]
push 0xf0
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x428089
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
je 0x4280a5
push ebx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
mov ecx, dword [ebp - 4]
push edi
call fcn.00427bbc
mov esi, eax
test edi, edi
je 0x4280a3
test ebx, ebx
je 0x4280a3
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x429081
Capabilities:
Get graphical window text

Disassembly:
push 4
mov eax, 0x45cf2e
call fcn.004428c8
mov esi, ecx
cmp dword [esi + 0x50], 0
jne 0x4290a6
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [esi + 0x20]
call dword [sym.imp.USER32.dll_GetWindowTextA]
jmp 0x4290ec
lea ecx, [ebp - 0x10]
call fcn.00401400
mov ecx, dword [esi + 0x50]
mov eax, dword [ecx]
and dword [ebp - 4], 0
lea edx, [ebp - 0x10]
push edx
call dword [eax + 0x8c]
push 0xffffffffffffffff
push dword [ebp - 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0042223b
add esp, 0x10
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
mov esi, eax
call fcn.004010e0
mov eax, esi
call fcn.004429a0
ret 8
Function at 0x42b9b9
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x160
mov eax, dword [0x4760f4]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 0xc], 0x800
mov eax, dword [ebp + 8]
push esi
mov dword [ebp - 0x11c], eax
mov esi, ecx
lea eax, [ebp - 0x120]
jne 0x42ba57
push 0x463e0c
push 4
push eax
call fcn.0044266f
push eax
call fcn.00417900
add esp, 0x10
push ebx
push edi
call fcn.00442e7e
mov edi, dword [eax]
call fcn.00442e7e
xor ebx, ebx
mov dword [eax], ebx
lea eax, [ebp - 0x120]
push eax
push dword [ebp - 0x11c]
lea eax, [ebp - 0x118]
push esi
push 0x111
mov esi, 0x112
push esi
push eax
call fcn.0043f798
add esp, 0x18
mov dword [ebp - 0x11c], eax
call fcn.00442e7e
cmp dword [eax], ebx
je 0x42ba6e
call fcn.00442e7e
push dword [eax]
call fcn.0042244b
pop ecx
jmp 0x42ba75
push 4
push eax
push 3
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
test eax, eax
jne 0x42b9ff
jmp 0x42bafc
call fcn.00442e7e
mov dword [eax], edi
cmp dword [ebp - 0x11c], 0xffffffff
je 0x42baf8
cmp dword [ebp - 0x11c], esi
jae 0x42baf8
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameA]
push 0x3c
mov esi, eax
lea eax, [ebp - 0x15c]
push ebx
push eax
mov dword [ebp - 0x160], 0x40
call fcn.0043f280
add esp, 0xc
push str.KERNEL32
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp eax, ebx
je 0x42bae7
push str.FindActCtxSectionStringA
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x42bae7
lea ecx, [ebp - 0x160]
push ecx
push esi
push 2
push ebx
push ebx
call eax
test eax, eax
je 0x42bae7
push ebx
push ebx
push esi
jmp 0x42baf0
push ebx
push ebx
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
jmp 0x42bafa
xor eax, eax
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0043efc3
leave
ret

Function at 0x42d75f
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
xor ebx, ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 4], ebx
cmp dword [ebp + 0xc], ebx
je 0x42d7a7
call fcn.0042a359
mov esi, dword [eax + 0xc]
push 0xf0
push dword [ebp + 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x42d7a7
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 4], eax
test eax, eax
je 0x42d7ea
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
mov esi, dword [ebp + 8]
mov dword [ebp + 0xc], 1
test ebx, ebx
je 0x42d7d3
push dword [ebp + 0x10]
mov eax, dword [edi]
push ebx
push esi
mov ecx, edi
call dword [eax + 0x20]
cmp dword [ebp - 4], 0
mov dword [ebp + 0xc], eax
je 0x42d7d3
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeResource]
cmp dword [esi + 0x4c], 0
je 0x42d7e7
mov ecx, dword [esi + 0x4c]
push dword [ebp + 0x10]
mov eax, dword [ecx]
call dword [eax + 0xa0]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x430b27
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
push dword [ebp + 8]
xor esi, esi
mov dword [ebp - 8], esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
cmp eax, 0xffffffff
jne 0x430b59
push dword [ebp + 8]
call edi
push eax
call fcn.0042feef
mov ebx, dword [ebp + 0xc]
movzx eax, byte [ebx + 0x20]
cmp eax, dword [ebp - 4]
je 0x430b84
test byte [ebp - 4], 1
je 0x430b84
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
jne 0x430b84
push dword [ebp + 8]
call edi
push eax
call fcn.0042feef
lea eax, [ebx + 8]
mov ecx, dword [eax]
or ecx, dword [eax + 4]
je 0x430c3e
lea ecx, [ebp - 0x20]
push ecx
push eax
call fcn.00430a89
pop ecx
lea eax, [ebx + 0x10]
pop ecx
mov ecx, dword [eax]
or ecx, dword [eax + 4]
je 0x430bba
lea ecx, [ebp - 0x10]
push ecx
push eax
call fcn.00430a89
pop ecx
lea eax, [ebp - 0x10]
pop ecx
mov dword [ebp - 8], eax
mov eax, dword [ebx]
or eax, dword [ebx + 4]
je 0x430bd0
lea eax, [ebp - 0x18]
push eax
push ebx
call fcn.00430a89
pop ecx
pop ecx
lea esi, [ebp - 0x18]
push 0
push 0x80
push 3
push 0
push 1
push 0xc0000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x430bfd
push dword [ebp + 8]
call edi
push eax
call fcn.0042feef
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 8]
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileTime]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x430c29
call edi
push ebx
mov dword [ebp - 8], eax
call esi
push dword [ebp + 8]
push dword [ebp - 8]
call fcn.0042feef
push ebx
call esi
test eax, eax
jne 0x430c3b
push dword [ebp + 8]
call edi
push eax
call fcn.0042feef
mov ebx, dword [ebp + 0xc]
movzx eax, byte [ebx + 0x20]
cmp eax, dword [ebp - 4]
je 0x430c66
test byte [ebp - 4], 1
jne 0x430c66
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
jne 0x430c66
push dword [ebp + 8]
call edi
push eax
call fcn.0042feef
pop edi
pop esi
pop ebx
leave
ret 8

Function at 0x43efc3
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4760f4]
jne 0x43efcd
repz ret
jmp fcn.004474bc
Function at 0x441b06
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x441b37
call fcn.00442e91
mov dword [eax], esi
call fcn.00442e7e
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.0043f5ef
add esp, 0x14
push 0x16
pop eax
jmp 0x441b8c
test dword [ebp + 0xc], 0xfffffff9
jne 0x441b13
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x441b64
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00442ea4
pop ecx
call fcn.00442e7e
mov eax, dword [eax]
jmp 0x441b8c
test al, 0x10
jne 0x441b8a
test al, 1
je 0x441b8a
test byte [ebp + 0xc], 2
je 0x441b8a
call fcn.00442e91
mov dword [eax], 5
call fcn.00442e7e
mov dword [eax], 0xd
jmp 0x441b5b
xor eax, eax
pop esi
pop ebp
ret

Function at 0x4528e4
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.00446e03
and dword [ebp - 4], 0
cmp dword [0x4a66c4], 0
mov ebx, eax
jne 0x452995
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x452a46
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x466818
push edi
call esi
test eax, eax
je 0x452a46
push eax
call fcn.00446d91
mov dword [esp], 0x466808
push edi
mov dword [0x4a66c4], eax
call esi
push eax
call fcn.00446d91
mov dword [esp], 0x4667f4
push edi
mov dword [0x4a66c8], eax
call esi
push eax
call fcn.00446d91
mov dword [esp], str.GetUserObjectInformationA
push edi
mov dword [0x4a66cc], eax
call esi
push eax
call fcn.00446d91
pop ecx
mov dword [0x4a66d4], eax
test eax, eax
je 0x452995
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.00446d91
pop ecx
mov dword [0x4a66d0], eax
mov eax, dword [0x4a66d0]
cmp eax, ebx
je 0x4529ed
cmp dword [0x4a66d4], ebx
je 0x4529ed
push eax
call fcn.00446e0c
push dword [0x4a66d4]
mov esi, eax
call fcn.00446e0c
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x4529ed
test edi, edi
je 0x4529ed
call esi
test eax, eax
je 0x4529e4
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x4529e4
test byte [ebp - 0xc], 1
jne 0x4529ed
or dword [ebp + 0x10], 0x200000
jmp 0x452a26
mov eax, dword [0x4a66c8]
cmp eax, ebx
je 0x452a26
push eax
call fcn.00446e0c
pop ecx
test eax, eax
je 0x452a26
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x452a26
mov eax, dword [0x4a66cc]
cmp eax, ebx
je 0x452a26
push eax
call fcn.00446e0c
pop ecx
test eax, eax
je 0x452a26
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x4a66c4]
call fcn.00446e0c
pop ecx
test eax, eax
je 0x452a46
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x452a48
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x401da0
Capabilities:
Get hostname
Resolve dns

Disassembly:
sub esp, 0x50
or ecx, 0xffffffff
xor eax, eax
push ebx
push ebp
push esi
push edi
mov edi, 0x410818
mov ebx, dword [esp + 0x64]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x40
mov eax, ecx
mov esi, edi
mov edi, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x24]
push ecx
call sub.WS2_32.dll_gethostname
lea edx, [esp + 0x20]
push edx
call dword [sym.imp.MSVCRT.dll__strlwr]
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x410020
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x20]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call sub.WS2_32.dll_gethostbyname
mov ebp, eax
test ebp, ebp
jne 0x401e53
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x50
ret
mov ecx, dword [ebp + 0xc]
mov esi, dword [ecx]
test esi, esi
je 0x401ef0
mov dword [esp + 0x64], 0
movsx ecx, word [ebp + 0xa]
mov edx, ecx
lea edi, [esp + 0x14]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x14]
push eax
call sub.WS2_32.dll_inet_ntoa
mov edi, eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x410020
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov eax, dword [esp + 0x64]
mov ecx, edx
and ecx, 3
add eax, 4
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 0xc]
mov dword [esp + 0x64], eax
mov esi, dword [ecx + eax]
test esi, esi
jne 0x401e68
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x50
ret
Function at 0x401f00
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0xc
push esi
push 0x100
call sub.MFC42.DLL_operatornew
mov ecx, dword [esp + 0x18]
add esp, 4
mov esi, eax
lea eax, [esp + 4]
push eax
push 0x20019
push 0
push ecx
mov byte [esi], 0
push connect
mov dword [esp + 0x20], 1
mov dword [esp + 0x1c], 0x100
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x401f56
push esi
call sub.MFC42.DLL_operatordelete
add esp, 4
xor eax, eax
pop esi
add esp, 0xc
ret
mov ecx, dword [esp + 0x18]
lea edx, [esp + 8]
push edx
mov edx, dword [esp + 8]
lea eax, [esp + 0x10]
push esi
push eax
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x401f92
push esi
call sub.MFC42.DLL_operatordelete
mov eax, dword [esp + 8]
add esp, 4
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop esi
add esp, 0xc
ret
mov ecx, dword [esp + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edx, dword [esp + 0x1c]
push 0x100
push esi
push edx
call dword [sym.imp.MSVCRT.dll_strncpy]
push esi
call sub.MFC42.DLL_operatordelete
add esp, 0x10
mov eax, 1
pop esi
add esp, 0xc
ret

Function at 0x401fd0
Capabilities:
Set registry value

Disassembly:
push ecx
mov edx, dword [esp + 8]
lea eax, [esp]
lea ecx, [esp + 8]
push eax
push ecx
push 0
push 0x20006
push 0
push 0
push 0
push edx
push connect
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x402000
xor eax, eax
pop ecx
ret
mov edx, dword [esp + 0x10]
push edi
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
mov ecx, dword [esp + 0x10]
push edx
push 1
push eax
mov eax, dword [esp + 0x20]
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
pop edi
je 0x40203a
mov edx, dword [esp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop ecx
ret
mov eax, dword [esp + 8]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
pop ecx
ret

Function at 0x402050
Capabilities:
Get common file path
Read .ini file

Disassembly:
sub esp, 0x100
push ebx
push esi
push edi
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], 0
push 0xff
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edi, str._svcprn.ini
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xc]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0x11c]
mov ecx, ebx
and ecx, 3
lea eax, [esp + 0xc]
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x118]
push eax
mov eax, dword [esp + 0x118]
push 0x100
push ecx
mov ecx, dword [esp + 0x11c]
push edx
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x100
ret
Function at 0x4020f0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x100
push ebx
push esi
push edi
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], 0
push 0xff
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edi, str._svcprn.ini
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xc]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0x114]
mov ecx, ebx
and ecx, 3
lea eax, [esp + 0xc]
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x118]
push eax
mov eax, dword [esp + 0x114]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x100
ret
Function at 0x402180
Capabilities:
Get hostname

Disassembly:
push 0xffffffffffffffff
push 0x40af3b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x4e4
push esi
push edi
mov ecx, 0xe9
xor eax, eax
lea edi, [esp + 0x148]
rep stosd dword es:[edi], eax
mov edi, dword [esp + 0x4fc]
lea esi, [edi + 0x380]
push esi
call fcn.00401da0
add esp, 4
lea eax, [esp + 0x46c]
push 0x40
push eax
call sub.WS2_32.dll_gethostname
lea ecx, [edi + 0x300]
push 0x40
push ecx
call sub.WS2_32.dll_gethostname
push esi
call dword [sym.imp.MSVCRT.dll__strlwr]
add esp, 4
lea ecx, [esp + 8]
call fcn.00405a20
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0
call fcn.00405a60
test eax, eax
jne 0x402239
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [esp + 0x4e4]
mov dword fs:[0], ecx
add esp, 0x4f0
ret
push 0x2710
lea ecx, [esp + 0xc]
call fcn.00405b80
mov edx, dword [esp + 0x500]
push 0x3138
push edx
lea ecx, [esp + 0x10]
call fcn.00405ae0
test eax, eax
jne 0x402298
lea ecx, [esp + 8]
call fcn.00405ab0
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [esp + 0x4e4]
mov dword fs:[0], ecx
add esp, 0x4f0
ret
lea eax, [esp + 0x148]
lea ecx, [esp + 8]
push eax
push 0x3a4
push 0x95
call fcn.00405c90
test eax, eax
jne 0x4022ee
lea ecx, [esp + 8]
call fcn.00405ab0
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [esp + 0x4e4]
mov dword fs:[0], ecx
add esp, 0x4f0
ret
push edi
push 0x584
push 0x91
lea ecx, [esp + 0x14]
call fcn.00405c90
test eax, eax
jne 0x40233d
lea ecx, [esp + 8]
call fcn.00405ab0
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [esp + 0x4e4]
mov dword fs:[0], ecx
add esp, 0x4f0
ret
mov ecx, 0x4c
xor eax, eax
lea edi, [esp + 0x18]
lea edx, [esp + 0x10]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x18]
lea eax, [esp + 0x14]
push ecx
push edx
push eax
lea ecx, [esp + 0x14]
call fcn.00405cd0
test eax, eax
lea ecx, [esp + 8]
jne 0x40239d
call fcn.00405ab0
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [esp + 0x4e4]
mov dword fs:[0], ecx
add esp, 0x4f0
ret
call fcn.00405ab0
mov eax, dword [esp + 0x18]
lea ecx, [esp + 8]
test eax, eax
je 0x4023e1
call fcn.00405ab0
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [esp + 0x4e4]
mov dword fs:[0], ecx
add esp, 0x4f0
ret
call fcn.00405ab0
lea ecx, [esp + 8]
mov dword [esp + 0x4f4], 0xffffffff
call fcn.00405a50
mov ecx, dword [esp + 0x4ec]
pop edi
xor eax, eax
pop esi
mov dword fs:[0], ecx
add esp, 0x4f0
ret