joyce8/EMBER2024-capa huggingface dataset:
Function at 0x5842d5
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push esi
mov eax, ebx
push edi
mov edi, ecx
shr eax, 0x10
test ax, ax
mov dword [edi + 0x40], ebx
jne 0x5842f7
cmp dword [edi + 0x3c], 0
jne 0x5842f7
movzx eax, bx
mov dword [edi + 0x3c], eax
call fcn.005928ec
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
mov ecx, edi
push dword [esp + 0x18]
push eax
call fcn.00584324
pop edi
pop esi
pop ebx
ret 8

Function at 0x58596e
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x5859a6
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.00588b01
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.00588ad9
jmp 0x5859b2
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4

Function at 0x5859b6
Capabilities:
Get graphical window text

Disassembly:
push esi
push edi
mov edi, dword [esp + 0x10]
mov esi, ecx
push 0x666210
mov ecx, edi
call fcn.00588849
cmp dword [esi + 0x34], 0
push dword [esp + 0xc]
jne 0x585a09
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetDlgItem]
mov esi, eax
test esi, esi
je 0x585a1c
push esi
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
push eax
mov ecx, edi
call fcn.00588b01
push eax
push esi
call dword [sym.imp.USER32.dll_GetWindowTextA]
push 0xffffffffffffffff
mov ecx, edi
call fcn.00588ad9
jmp 0x585a1c
mov ecx, esi
call fcn.00587abb
test eax, eax
je 0x585a1c
push edi
mov ecx, eax
call fcn.0058596e
mov eax, dword [edi]
pop edi
pop esi
mov eax, dword [eax - 8]
ret 8

Function at 0x587251
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x587293
call fcn.005928ec
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x587293
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x58728a
xor eax, eax
jmp 0x58729b
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.005872a1
pop edi
pop esi
pop ebx
ret 4
Function at 0x593a38
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov dword [ebp - 8], ecx
call fcn.005928ec
mov esi, dword [eax + 0xc]
push 0xf1
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x593a75
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x593a75
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
jne 0x593a79
xor eax, eax
jmp 0x593af7
movzx eax, word [esi + 6]
push ebx
push edi
shl eax, 2
push eax
call fcn.00584a5c
and dword [ebp - 4], 0
cmp word [esi + 6], 0
pop ecx
mov ebx, eax
jbe 0x593ab1
mov ecx, ebx
lea eax, [esi + 8]
movzx edx, word [eax]
inc dword [ebp - 4]
mov dword [ecx], edx
movzx edx, word [esi + 6]
inc eax
add ecx, 4
inc eax
cmp dword [ebp - 4], edx
jl 0x593a9b
movzx eax, word [esi + 6]
mov ecx, dword [ebp - 8]
push eax
push ebx
call fcn.00593be8
push ebx
mov edi, eax
call fcn.00584a85
test edi, edi
pop ecx
je 0x593af3
movzx ecx, word [esi + 4]
movzx eax, word [esi + 2]
lea esi, [ecx + 7]
push ecx
mov ecx, dword [ebp - 8]
lea edx, [eax + 7]
push eax
push esi
push edx
call fcn.005939b1
push dword [ebp + 8]
mov ecx, dword [ebp - 8]
call fcn.00593afc
mov edi, eax
mov eax, edi
pop edi
pop ebx
pop esi
leave
ret 4

Function at 0x596926
Capabilities:
Check for time delay via gettickcount
Log keystrokes via polling

Disassembly:
sub esp, 0x20
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov edi, dword [sym.imp.USER32.dll_GetKeyState]
xor ebx, ebx
push 1
mov dword [esi + 0x30], ebx
mov dword [esi + 0x34], ebx
mov dword [esi + 0x38], ebx
call edi
test ax, ax
jge 0x59694e
or dword [esi + 0x38], 1
or dword [esi + 0x34], 2
jmp 0x59695f
push 2
call edi
test ax, ax
jge 0x59695f
or dword [esi + 0x38], 2
or dword [esi + 0x34], 1
mov ebp, dword [sym.imp.KERNEL32.dll_GetTickCount]
call ebp
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x34]
push dword [eax + 0x1c]
call dword [sym.imp.USER32.dll_SetCapture]
push eax
call fcn.00584fbf
cmp dword [esi + 0x30], ebx
jne 0x596a39
mov edi, dword [sym.imp.USER32.dll_PeekMessageA]
mov ebx, pe_nt_image_headers32
call dword [sym.imp.USER32.dll_GetCapture]
push eax
call fcn.00584fbf
cmp eax, dword [esp + 0x34]
jne 0x596a39
push 1
push 0x209
push 0x200
lea eax, [esp + 0x20]
push 0
push eax
call edi
test eax, eax
jne 0x5969d5
push 1
push 0x108
push ebx
push eax
lea eax, [esp + 0x24]
push eax
call edi
test eax, eax
je 0x596a1a
mov eax, dword [esp + 0x18]
cmp eax, 0x202
je 0x596a39
cmp eax, 0x205
je 0x596a39
cmp eax, 0x201
je 0x596a39
cmp eax, 0x204
je 0x596a39
cmp eax, ebx
jne 0x596a00
cmp dword [esp + 0x1c], 0x1b
je 0x596a39
push dword [esp + 0x2c]
lea eax, [esi + 0x20]
push dword [esp + 0x2c]
push eax
call dword [sym.imp.USER32.dll_PtInRect]
neg eax
sbb eax, eax
inc eax
mov dword [esi + 0x30], eax
call ebp
sub eax, dword [esp + 0x10]
cmp eax, dword [0x666420]
jbe 0x596a2f
mov dword [esi + 0x30], 1
cmp dword [esi + 0x30], 0
je 0x596992
call dword [sym.imp.USER32.dll_ReleaseCapture]
mov eax, dword [esi + 0x30]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
Function at 0x10013126
Capabilities:
Query or enumerate registry value

Disassembly:
push 0x18
mov eax, 0x1002ba70
call fcn.1002a480
lea edi, [ecx + 0x164]
xor ebx, ebx
push 0x100064ac
mov ecx, edi
mov dword [ebp - 4], ebx
mov dword [ebp - 0x20], ebx
call fcn.1001bce8
test eax, eax
je 0x1001326c
push 0x100064c0
lea ecx, [ebp - 0x10]
call fcn.1001bce8
push 0x10006530
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 1
call fcn.1001bce8
push 0x100062f4
lea ecx, [ebp - 0x10]
call fcn.1001bce8
push dword [ebp + 0xc]
lea ecx, [ebp - 0x10]
call fcn.1001bce8
lea eax, [ebp - 0x14]
push eax
push 0x20019
push ebx
lea ecx, [ebp - 0x10]
call fcn.10020bd7
push eax
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
js 0x1001325e
cmp dword [ebp - 0x14], ebx
je 0x1001325e
push 0x100062d0
mov ecx, edi
mov dword [ebp - 0x24], 4
mov dword [ebp - 0x1c], ebx
call fcn.1001bce8
test eax, eax
jne 0x10013216
mov eax, 0x100054b6
mov esi, ebx
mov dword [ebp - 0x18], eax
push eax
push dword [ebp + 8]
call dword [sym.imp.MSVCR100.dll_wcsstr]
pop ecx
pop ecx
test eax, eax
jne 0x10013202
mov eax, dword [ebp - 0x18]
add eax, 0x3fc
inc esi
mov dword [ebp - 0x18], eax
cmp eax, 0x100064a6
jl 0x100131dd
jmp 0x10013216
imul esi, esi, 0x3fc
add esi, 0x100052b8
push esi
mov ecx, edi
call fcn.1001bce8
mov ecx, edi
call fcn.10020bd7
mov ecx, edi
test eax, eax
je 0x1001324b
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x1c]
push eax
push ebx
push ebx
call fcn.10020bd7
push eax
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x10013255
cmp dword [ebp - 0x1c], eax
setne al
mov dword [ebp - 0x20], eax
jmp 0x10013255
push 0x100064ac
call fcn.1001bce8
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], bl
call fcn.1002161e
mov ebx, dword [ebp - 0x20]
push dword [ebp + 0xc]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, ebx
call fcn.1002a558
ret 8
Function at 0x10013779
Capabilities:
Get file size
Read file via mapping

Disassembly:
push 0x58
mov eax, 0x1002bb11
call fcn.1002a4e9
mov edi, ecx
mov eax, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
or dword [edi + 4], 0xffffffff
mov dword [ebp - 0x60], eax
xor eax, eax
mov dword [edi], 0x1000641c
mov dword [edi + 8], eax
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], eax
mov dword [edi + 0x14], eax
mov dword [edi + 0x18], eax
call dword [sym.imp.kernel32.dll_GetVersion]
cmp eax, 0x80000000
sbb esi, esi
mov ecx, ebx
neg esi
call fcn.10020bd7
push eax
lea ecx, [ebp - 0x64]
call dword [sym.imp.mfc100.dll_Ordinal_306]
push 0
push 0x80
neg esi
push 3
sbb esi, esi
push 0
and esi, 4
or esi, 1
push esi
push SysReAllocString
push dword [eax]
call dword [sym.imp.kernel32.dll_CreateFileA]
lea ecx, [ebp - 0x64]
mov dword [edi + 4], eax
call dword [sym.imp.mfc100.dll_Ordinal_901]
cmp dword [edi + 4], 0xffffffff
jne 0x100138e4
and dword [ebp - 0x58], 0
call dword [sym.imp.kernel32.dll_GetLastError]
push 0
mov esi, eax
lea eax, [ebp - 0x58]
push 0
push eax
call fcn.1001bce8
movzx eax, ax
push eax
push esi
push 0
push 0x1300
call dword [sym.imp.kernel32.dll_FormatMessageA]
push 1
mov esi, 0x1802
push esi
lea ecx, [ebp - 0x5c]
call fcn.1001bce8
and dword [ebp - 4], 0
call fcn.1001bce8
movzx eax, ax
push eax
push dword [ebp - 0x60]
lea ecx, [ebp - 0x5c]
push esi
call fcn.1001bce8
push 0x40
lea ecx, [ebp - 0x5c]
call fcn.10020bd7
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.1001bce8
add esp, 0xc
mov ecx, ebx
call fcn.10020bd7
push eax
lea ecx, [ebp - 0x54]
call dword [sym.imp.mfc100.dll_Ordinal_306]
push 0x10006430
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], 1
call dword [sym.imp.mfc100.dll_Ordinal_1483]
push dword [ebp - 0x58]
lea ecx, [ebp - 0x54]
call dword [sym.imp.mfc100.dll_Ordinal_1483]
mov esi, dword [ebp - 0x54]
call fcn.1001bce8
movzx eax, ax
push eax
push 0x40
lea eax, [ebp - 0x50]
push eax
push esi
push 0
call dword [sym.imp.USER32.dll_MessageBoxExA]
push dword [ebp - 0x58]
call dword [sym.imp.kernel32.dll_LocalFree]
and dword [ebp - 0x58], 0
mov ecx, edi
call fcn.100139d5
lea ecx, [ebp - 0x54]
call dword [sym.imp.mfc100.dll_Ordinal_901]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x5c]
call fcn.1002161e
jmp 0x10013930
xor ebx, ebx
push ebx
push ebx
push ebx
push 2
push ebx
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_CreateFileMappingA]
mov dword [edi + 8], eax
test eax, eax
je 0x10013929
push ebx
push ebx
push ebx
push 4
push eax
call dword [sym.imp.kernel32.dll_MapViewOfFile]
mov dword [edi + 0xc], eax
test eax, eax
je 0x10013929
push ebx
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_GetFileSize]
push eax
push dword [edi + 0xc]
call fcn.1001bce8
mov dword [edi + 0x10], eax
test eax, eax
jne 0x10013930
mov ecx, edi
call fcn.100139d5
mov eax, edi
call fcn.1002a56c
ret 8
Function at 0x10018e95
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push 0x428
mov eax, 0x1002bda3
call fcn.1002a51f
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov dword [ebp - 0x420], eax
mov eax, dword [ebp + 0x10]
xor ebx, ebx
mov dword [ebp - 0x424], eax
mov dword [ebp - 0x428], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x42c], ecx
mov dword [ebp - 0x430], ebx
mov dword [ebp - 0x418], ebx
mov byte [ebp - 4], 1
test edi, edi
je 0x10019069
push edi
call dword [sym.imp.kernel32.dll_lstrlenW]
inc eax
push 2
push eax
mov dword [ebp - 0x41c], eax
lea eax, [ebp - 0x41c]
push eax
call fcn.1001bce8
add esp, 0xc
test eax, eax
js 0x10019063
mov esi, dword [ebp - 0x41c]
cmp esi, 0x400
jg 0x10018f31
push esi
call fcn.100158b3
pop ecx
test al, al
je 0x10018f31
mov eax, esi
call fcn.1002a74c
mov dword [ebp - 0x10], esp
mov eax, esp
jmp 0x10018f3d
push esi
lea ecx, [ebp - 0x428]
call fcn.1001bce8
push 3
push esi
push edi
push eax
call fcn.1001bce8
test eax, eax
je 0x10019063
push 2
push ebx
push eax
call dword [sym.imp.kernel32.dll_LoadLibraryExA]
mov edi, eax
mov dword [ebp - 0x41c], edi
test edi, edi
jne 0x10018f71
call fcn.10015ac7
mov esi, eax
jmp 0x10019048
push dword [ebp - 0x424]
push dword [ebp - 0x420]
push edi
call dword [sym.imp.kernel32.dll_FindResourceA]
mov esi, eax
test esi, esi
jne 0x10018f94
call fcn.10015ac7
jmp 0x1001903f
push esi
push edi
call dword [sym.imp.kernel32.dll_LoadResource]
mov dword [ebp - 0x424], eax
test eax, eax
je 0x10018f8a
push esi
push edi
call dword [sym.imp.kernel32.dll_SizeofResource]
mov esi, eax
lea eax, [esi + 1]
mov dword [ebp - 0x420], esi
cmp eax, esi
jae 0x10018fc4
mov esi, 0x8007000e
jmp 0x10019041
push eax
lea ecx, [ebp - 0x418]
mov byte [ebp - 4], 2
call fcn.1001bce8
mov dword [ebp - 4], 1
jmp 0x10019003
cmp dword [ebp - 0x418], 0
je 0x10018fbd
push esi
push dword [ebp - 0x424]
push esi
push dword [ebp - 0x418]
call fcn.1001bce8
mov eax, dword [ebp - 0x418]
add esp, 0x10
push dword [ebp + 0x14]
mov byte [eax + esi], bl
push dword [ebp - 0x418]
lea ecx, [ebp - 0x430]
call fcn.1001bce8
mov esi, eax
push edi
call dword [sym.imp.kernel32.dll_FreeLibrary]
lea eax, [ebp - 0x414]
cmp dword [ebp - 0x418], eax
je 0x10019083
lea ecx, [ebp - 0x418]
call fcn.1001914a
jmp 0x10019083
mov ebx, dword [ebp - 0x418]
lea eax, [ebp - 0x414]
cmp ebx, eax
je 0x1001907e
lea ecx, [ebp - 0x418]
call fcn.1001914a
mov esi, 0x8007000e
lea ecx, [ebp - 0x428]
call fcn.1000cc87
mov eax, esi
lea esp, [ebp - 0x444]
call fcn.1002a578
ret 0x10
Function at 0x1001bce8
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
pushal
call 0x1001bcf7
pop dword [ebp - 0x38]
mov eax, 0x7b508753
add eax, 0x94b135a4
sub dword [ebp - 0x38], eax
mov dword [ebp - 0x48], 0x8817979b
sub dword [ebp - 0x48], 0x39c55250
mov dword [ebp - 0x44], 0x6717d36
sub dword [ebp - 0x44], 0xd43e30f1
mov dword [ebp - 0x40], 0xa9105ab0
sub dword [ebp - 0x40], 0x5cc41682
mov dword [ebp - 0x3c], 0x73ea529e
sub dword [ebp - 0x3c], 0x73ea529e
lea eax, [ebp - 0x48]
push eax
mov eax, 0x770d9480
sub eax, 0x670d840c
add eax, dword [ebp - 0x38]
call dword [eax]
mov dword [ebp - 0x48], 0xc4611d5a
add dword [ebp - 0x48], 0xb0114bfc
mov dword [ebp - 0x44], 0xf074703e
sub dword [ebp - 0x44], 0xaf080ec9
mov dword [ebp - 0x40], 0x247dd336
sub dword [ebp - 0x40], 0xc10e66ca
mov dword [ebp - 0x3c], 0xccaa2e7e
sub dword [ebp - 0x3c], 0xccaa2e7e
lea ebx, [ebp - 0x48]
push ebx
push eax
mov eax, 0xfabc1043
add eax, 0x1544002d
add eax, dword [ebp - 0x38]
call dword [eax]
push 0x40
push 0x1000
push 0x3d542
push 0
call eax
mov ecx, 0x4a736f2
sub ecx, 0x4a6ef08
xor edx, edx
add edx, eax
mov ebx, 0x1003ae00
add ebx, dword [ebp - 0x38]
mov edi, 0xa72a2da0
sub edi, 0xe969deee
sub dword [ebp - 0xc], 0xe3e6b73a
mov esi, dword [ebx]
add dword [ebp - 0x28], edx
add esi, edi
sub dword [ebp - 0x34], 0x969ce9f8
mov dword [edx], esi
xor dword [ebp - 0xc], 0xda234031
add edx, 0xdc607d97
sub edx, 0xdc607d93
add ebx, 4
loop 0x1001be15
add eax, 0xcb2466a3
add eax, 0x34dcabd8
mov ebx, eax
add eax, 0x40bf264a
add eax, 0xbf40d9bb
mov ecx, 0x10000000
add ecx, dword [ebp - 0x38]
call ebx
leave
ret
Function at 0x403380
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42e3c9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::CString_2
mov dword [ebp - 4], 0
push str.download_rand
lea eax, [ebp - 0x10]
push eax
call sub.MFC42.DLL_CString::Format
add esp, 8
push 0
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::GetBuffer
push eax
call sub.LIBEAY32.dll_Ordinal_470
add esp, 4
push 0x400
push 0
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::GetBuffer
push eax
call sub.LIBEAY32.dll_Ordinal_467
add esp, 8
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::CString
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret

Function at 0x403410
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42e3f2
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x24
lea ecx, [ebp - 0x1c]
call fcn.0042deca
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::CString_2
mov byte [ebp - 4], 1
cmp dword [ebp + 0xc], 0
jne 0x40345a
mov eax, dword [ebp + 8]
push eax
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::operator_1
jmp 0x403498
cmp dword [ebp + 0x10], 0
je 0x40347f
mov ecx, dword [ebp + 8]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 0x10]
push eax
push str._s_s_s
lea ecx, [ebp - 0x24]
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0x14
jmp 0x403498
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp + 0xc]
push eax
push 0x43b1d8
lea ecx, [ebp - 0x24]
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0x10
push 0
push 0
mov edx, dword [ebp - 0x24]
push edx
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CFile::Open
test eax, eax
jne 0x40350f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 2
je 0x4034c1
cmp dword [ebp - 0x20], 3
jne 0x4034e8
mov dword [ebp - 0x28], 0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CFile::CFile
mov eax, dword [ebp - 0x28]
jmp 0x403534
mov dword [ebp - 0x2c], 0xffffffff
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CFile::CFile
mov eax, dword [ebp - 0x2c]
jmp 0x403534
mov dword [ebp - 0x30], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CFile::CFile
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
Function at 0x40b300
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42ed39
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x14
mov dword [ebp - 0x20], ecx
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::CString_2
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax + 4]
push ecx
push str.download_s
lea edx, [ebp - 0x14]
push edx
call sub.MFC42.DLL_CString::Format
add esp, 0xc
push 0
push 0
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::GetBuffer
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x40b3a1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xb7
je 0x40b3a1
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x20]
mov edx, dword [ecx + 4]
push edx
push str.ERROR:_DOWNLOAD:_Cannot_create_Id_directory__s___i__n
call dword [sym.imp.SysInfo.dll_void___cdecl_AddLog_char_const__]
add esp, 0xc
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x18], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp - 0x18]
jmp 0x40b3ba
mov dword [ebp - 0x1c], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret

Function at 0x40c9b0
Capabilities:
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42ef96
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
mov dword [ebp - 0x14], ecx
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x14]
add eax, 0x30
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x10]
mov dword [ecx], 0x432914
mov edx, dword [ebp - 0x10]
add edx, 8
push edx
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
mov ecx, dword [ebp - 0x10]
call fcn.0042dfde
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x14]
mov dword [eax], 0x432884
mov dword [ebp - 4], 4
mov ecx, dword [ebp - 0x14]
add ecx, 0x1c
call sub.MFC42.DLL_CString::CString
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x14]
add ecx, 0x18
call sub.MFC42.DLL_CString::CString
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x14]
add ecx, 0x10
call sub.MFC42.DLL_CString::CString
mov byte [ebp - 4], 1
mov ecx, dword [ebp - 0x14]
add ecx, 4
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x14]
mov dword [ecx], 0x4328ac
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
Function at 0x416350
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42fc03
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x110
mov dword [ebp - 0x11c], 0
lea eax, [ebp - 0x118]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::CString_2
mov dword [ebp - 4], 1
cmp dword [ebp + 0xc], 0
jne 0x4163be
push str.ocsinventory.conf
lea ecx, [ebp - 0x118]
push ecx
push 0x43b1d8
lea edx, [ebp - 0x10]
push edx
call sub.MFC42.DLL_CString::Format
add esp, 0x10
jmp 0x4163db
push str.admininfo.conf
lea eax, [ebp - 0x118]
push eax
push 0x43b1d8
lea ecx, [ebp - 0x10]
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0x10
lea edx, [ebp - 0x10]
push edx
mov ecx, dword [ebp + 8]
call sub.MFC42.DLL_CString::CString_1
mov eax, dword [ebp - 0x11c]
or al, 1
mov dword [ebp - 0x11c], eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
Function at 0x404837
Capabilities:
Get disk information

Disassembly:
mov eax, 0x429b10
call fcn.00428650
sub esp, 0x20
push ebx
push esi
push edi
mov dword [ebp - 0x10], ecx
call fcn.00401f1f
mov edi, dword [sym.imp.kernel32.dll_GetLogicalDriveStringsW]
push 0
push 0
call edi
mov ebx, eax
test ebx, ebx
mov dword [ebp - 0x18], ebx
je 0x40490d
mov eax, SysReAllocString
cmp ebx, eax
ja 0x404873
mov eax, ebx
add eax, eax
push eax
call fcn.00405733
mov esi, eax
pop ecx
mov dword [ebp - 0x20], esi
and dword [ebp - 4], 0
push esi
push ebx
call edi
mov ebx, eax
xor edi, edi
cmp ebx, edi
mov dword [ebp - 0x14], ebx
je 0x404906
cmp ebx, dword [ebp - 0x18]
ja 0x404906
lea ecx, [ebp - 0x2c]
call fcn.00402679
test ebx, ebx
mov byte [ebp - 4], 1
mov dword [ebp - 0x18], edi
jbe 0x4048ee
push 2
xor eax, eax
pop ebx
cmp word [esi + ebx - 2], 0
jne 0x4048e3
add eax, esi
lea ecx, [ebp - 0x2c]
push eax
call fcn.00405733
mov ecx, dword [ebp - 0x10]
lea eax, [edi + 1]
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], ebx
call fcn.00405733
mov ecx, dword [ebp - 0x10]
lea eax, [ebp - 0x2c]
push eax
call fcn.00401d25
mov eax, ebx
inc edi
inc ebx
inc ebx
cmp edi, dword [ebp - 0x14]
jb 0x4048b1
mov ebx, dword [ebp - 0x14]
push dword [ebp - 0x2c]
call fcn.00402153
push esi
call fcn.00402153
cmp dword [ebp - 0x18], ebx
pop ecx
pop ecx
sete al
jmp 0x40490f
push esi
call fcn.00402153
pop ecx
xor al, al
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x405733
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
pushal
call 0x405742
pop dword [ebp - 0x48]
mov eax, 0x405742
sub dword [ebp - 0x48], eax
push 0x40
push 0x1000
push 0x3b62e
push 0
mov eax, 0xf89cb2b9
sub eax, 0xf859f28d
add eax, dword [ebp - 0x48]
call dword [eax]
mov ecx, 0x584a247f
sub ecx, 0x5849d40f
mov edx, eax
mov ebx, 0xd73b09fb
sub ebx, 0xd6f751fb
add ebx, dword [ebp - 0x48]
mov edi, 0xcb237111
sub edi, 0x7e75cb18
sub dword [ebp - 0xc], 0xf2144b22
mov esi, dword [ebx]
add esi, edi
xor dword [ebp - 0x34], edx
mov dword [edx], esi
xor dword [ebp - 0x2c], ebx
add edx, 0x8c787df3
sub edx, 0x8c787def
add ebx, 0xbe66fa38
sub ebx, 0xbe66fa34
loop 0x40579c
add eax, 0xfd7a5ce0
sub eax, 0xfd79284d
mov ebx, eax
add eax, 5
mov ecx, 0x400000
add ecx, dword [ebp - 0x48]
call ebx
leave
ret