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

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov eax, dword [eax + 8]
push ebx
push esi
xor esi, esi
sub eax, esi
push edi
je 0x4128e7
sub eax, 1
je 0x4128ba
sub eax, 1
je 0x4128b0
push 0x8e
push str.boralibmischashTable.c
push str.NOT_REACHED__s:_d_n
call fcn.0040fcf0
imul ecx, ecx, 0xbc8f
mov esi, ecx
jmp 0x4128ff
movzx eax, byte [ecx]
mov ebx, dword [sym.imp.MSVCR90.dll_tolower]
push eax
mov edi, ecx
call ebx
add esp, 4
test eax, eax
je 0x4128ff
nop
xor eax, esi
inc edi
rol eax, 5
mov esi, eax
movzx eax, byte [edi]
push eax
call ebx
add esp, 4
test eax, eax
jne 0x4128d0
jmp 0x4128ff
movzx eax, byte [ecx]
test eax, eax
je 0x4128ff
mov edi, edi
xor eax, esi
inc ecx
rol eax, 5
mov esi, eax
movzx eax, byte [ecx]
test eax, eax
jne 0x4128f0
mov ecx, dword [ebp + 8]
mov ecx, dword [ecx + 4]
mov eax, 1
shl eax, cl
dec eax
cmp esi, eax
jbe 0x412921
mov edx, esi
shr edx, cl
mov edi, eax
and edi, esi
xor edx, edi
mov esi, edx
cmp esi, eax
ja 0x412911
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret

Function at 0x4136d0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
call fcn.00413640
mov eax, dword [0x46ac7c]
cmp eax, 0xffffffff
jne 0x4136ec
call fcn.00413640
mov eax, dword [0x46ac7c]
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push eax
call esi
test eax, eax
jne 0x413744
mov esi, dword [ebp + 8]
mov eax, dword [0x46ac7c]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_TlsSetValue]
push esi
push eax
call edi
test al, al
je 0x413727
mov eax, dword [esi]
mov ecx, dword [0x46ac80]
inc eax
push eax
push ecx
call edi
test al, al
je 0x413727
mov al, 1
jmp 0x413729
xor al, al
mov bl, 1
pop edi
test al, al
jne 0x413781
push 0x271
push 0x44f970
push str.VERIFY__s:_d_n
call fcn.0040fcf0
mov eax, dword [0x46ac7c]
xor bl, bl
cmp eax, 0xffffffff
jne 0x41375a
call fcn.00413640
mov eax, dword [0x46ac7c]
push eax
call esi
mov ecx, dword [ebp + 8]
lea edx, [ecx + 4]
mov ecx, dword [ecx]
push edx
push ecx
lea edx, [eax + 4]
mov eax, dword [eax]
push edx
push eax
push str.VThreadBase_reinitialization__old:__d__s__new:__d__s._n
call fcn.00412850
add esp, 0x14
pop esi
mov al, bl
pop ebx
pop ebp
ret
mov eax, 0x46ac88
mov ecx, 1
lock xadd dword [eax], ecx
pop esi
mov al, bl
pop ebx
pop ebp
ret

Function at 0x4139b0
Capabilities:
Get thread local storage value

Disassembly:
mov eax, dword [0x46ac7c]
cmp eax, 0xffffffff
jne 0x4139c4
call fcn.00413640
mov eax, dword [0x46ac7c]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
jne 0x4139f6
cmp dword [0x46c630], eax
jne 0x4139fa
mov eax, 0x46c630
mov ecx, 1
lock xadd dword [eax], ecx
call fcn.004138d0
mov edx, 0x46c630
or ecx, 0xffffffff
lock xadd dword [edx], ecx
add eax, 4
ret
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str.host__Iu
push 0x2f
push 0x46c634
call dword [sym.imp.MSVCR90.dll__snprintf]
add esp, 0x10
mov eax, 0x46c634
ret
Function at 0x417f50
Capabilities:
Encode data using base64

Disassembly:
push ebp
mov ebp, esp
push ecx
mov ecx, dword [ebp + 0x10]
push ebx
push esi
mov esi, dword [ebp + 0xc]
lea edx, [esi + 2]
mov bl, 1
push edi
mov dword [ebp - 4], ecx
mov byte [ebp + 0x13], bl
cmp edx, esi
jb 0x418084
mov eax, dword [ebp + 0x14]
cmp eax, 1
jb 0x418084
lea edi, [eax - 1]
mov eax, 0xaaaaaaab
mul edx
shr edi, 2
shr edx, 1
cmp edx, edi
ja 0x418084
cmp esi, 2
jbe 0x41801d
lea edx, [esi - 3]
mov eax, 0xaaaaaaab
mul edx
mov eax, dword [ebp + 8]
mov edi, edx
shr edi, 1
inc edi
mov edi, edi
movzx edx, byte [eax]
shr edx, 2
movzx edx, byte [edx + 0x451f20]
mov byte [ecx], dl
movzx edx, byte [eax]
movzx ebx, byte [eax + 1]
and edx, 3
shl edx, 4
shr ebx, 4
or edx, ebx
movzx edx, byte [edx + 0x451f20]
mov byte [ecx + 1], dl
movzx edx, byte [eax + 1]
movzx ebx, byte [eax + 2]
and edx, 0xf
add edx, edx
add edx, edx
shr ebx, 6
or edx, ebx
movzx edx, byte [edx + 0x451f20]
mov byte [ecx + 2], dl
movzx edx, byte [eax + 2]
and edx, 0x3f
movzx edx, byte [edx + 0x451f20]
mov byte [ecx + 3], dl
sub esi, 3
add eax, 3
add ecx, 4
sub edi, 1
jne 0x417fb0
mov bl, byte [ebp + 0x13]
jmp 0x418020
mov eax, dword [ebp + 8]
mov edx, esi
dec esi
test edx, edx
je 0x41807f
test esi, esi
je 0x418030
mov dl, byte [eax + 1]
jmp 0x418032
xor dl, dl
movzx edi, byte [eax]
shr edi, 2
mov bl, byte [edi + 0x451f20]
mov byte [ecx], bl
movzx eax, byte [eax]
movzx edx, dl
and eax, 3
shl eax, 4
mov edi, edx
shr edi, 4
or eax, edi
mov al, byte [eax + 0x451f20]
mov byte [ecx + 1], al
test esi, esi
je 0x41806d
and edx, 0xf
movsx eax, byte [edx*4 + 0x451f20]
jmp 0x418072
mov eax, 0x3d
mov bl, byte [ebp + 0x13]
mov byte [ecx + 2], al
mov byte [ecx + 3], 0x3d
add ecx, 4
mov byte [ecx], 0
jmp 0x418086
xor bl, bl
mov eax, dword [ebp + 0x18]
test eax, eax
je 0x418092
sub ecx, dword [ebp - 4]
mov dword [eax], ecx
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x418760
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0x46b138], 0
je 0x4187dc
lea eax, [ebp - 4]
push eax
push 0x20019
push 0
push str.SOFTWAREMicrosoftCryptography
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [ebp - 0xc], 1
mov dword [ebp - 8], 0x2f
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x4187a5
mov eax, 0x4441a6
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 4]
push esi
lea ecx, [ebp - 8]
push ecx
push 0x46c688
lea edx, [ebp - 0xc]
push edx
push 0
push str.MachineGuid
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov ecx, dword [ebp - 4]
push ecx
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
pop esi
jne 0x41879c
mov byte [0x46b138], 0
mov eax, 0x46c688
mov esp, ebp
pop ebp
ret
Function at 0x419d40
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
xor eax, eax
xor bl, bl
push esi
mov byte [ebp - 4], bl
mov word [ebp - 3], ax
call dword [sym.imp.MSVCR90.dll___iob_func]
mov esi, dword [ebp + 8]
cmp esi, eax
jne 0x419d66
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
push esi
push 1
lea ecx, [ebp - 4]
push 3
push ecx
call dword [sym.imp.MSVCR90.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x419d97
cmp byte [ebp - 4], 0xef
jne 0x419d97
cmp byte [ebp - 3], 0xbb
jne 0x419d97
cmp byte [ebp - 2], 0xbf
jne 0x419d97
pop esi
mov bl, al
pop ebx
mov esp, ebp
pop ebp
ret
push esi
call dword [sym.imp.MSVCR90.dll_rewind]
add esp, 4
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x421a10
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
push 1
push eax
call fcn.004110e0
mov ebx, dword [ebp + 0x18]
xor edi, edi
add esp, 8
mov esi, eax
mov dword [ebp - 0xc], esi
mov dword [ebp - 4], edi
cmp ebx, edi
je 0x421a50
mov ecx, dword [ebp + 0x1c]
mov eax, dword [ecx]
add eax, eax
mov dword [ebp - 4], eax
add eax, 2
push eax
call fcn.0040a640
add esp, 4
mov edi, eax
mov ecx, dword [ebp + 0x10]
lea edx, [ebp - 4]
push edx
mov edx, dword [ebp + 8]
push edi
lea eax, [ebp - 8]
push eax
push ecx
push esi
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov esi, eax
test edi, edi
je 0x421a8d
test esi, esi
jne 0x421a8d
cmp dword [ebp - 8], 1
jne 0x421a8d
mov ecx, dword [ebp - 4]
push 1
push edi
mov word [ecx + edi], ax
call fcn.00406830
add esp, 8
mov dword [ebp - 4], eax
mov edx, dword [ebp - 4]
mov ecx, dword [ebp - 8]
push edx
mov eax, esi
mov esi, dword [ebp + 0x1c]
push edi
mov edx, ebx
call fcn.004218e0
mov esi, eax
mov eax, dword [ebp + 0x14]
add esp, 8
test eax, eax
je 0x421ab2
mov ecx, dword [ebp - 8]
mov dword [eax], ecx
mov edx, dword [ebp - 0xc]
mov ebx, dword [sym.imp.MSVCR90.dll_free]
push edx
call ebx
push edi
call ebx
add esp, 8
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4242b0
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa0
mov eax, dword [0x4620c8]
xor eax, ebp
mov dword [ebp - 4], eax
mov al, byte [0x46b93c]
test al, al
jne 0x4242df
mov eax, dword [0x46cc70]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00405fa8
mov esp, ebp
pop ebp
ret
push 0x9c
lea ecx, [ebp - 0xa0]
push 0
push ecx
call sub.MSVCR90.dll_memset
add esp, 0xc
lea edx, [ebp - 0xa0]
push edx
mov dword [ebp - 0xa0], 0x9c
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x424328
mov dword [0x46cc70], eax
mov byte [0x46b93c], al
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00405fa8
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x9c]
cmp eax, 5
jbe 0x42433a
mov eax, 8
jmp 0x424351
jne 0x42434f
mov eax, dword [ebp - 0x98]
test eax, eax
ja 0x424333
jne 0x42434f
cmp word [ebp - 0xc], 4
jae 0x424333
xor eax, eax
mov dword [0x46cc70], eax
mov byte [0x46b93c], 0
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00405fa8
mov esp, ebp
pop ebp
ret

Function at 0x426050
Capabilities:
Query environment variable

Disassembly:
mov eax, dword [0x46cd00]
test eax, eax
jne 0x42607e
push str.ICU_DATA
call dword [sym.imp.MSVCR90.dll_getenv]
add esp, 4
test eax, eax
jne 0x426070
mov eax, 0x4441a6
push eax
call fcn.00425f60
mov eax, dword [0x46cd00]
add esp, 4
ret
Function at 0x429d30
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push ebx
xor esi, esi
call fcn.00428dd0
mov eax, dword [ebp + 0xc]
add esp, 4
push esi
push 0x10000080
push 3
push esi
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x429d89
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
push str.uprv_mapFile:_CreateFileA_failed_for__s___d__n
call fcn.00412850
add esp, 0xc
pop edi
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
push 1
lea edx, [ebp - 0x20]
push edx
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
test eax, eax
je 0x429dcb
push 0
push 0
push 1
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
test eax, eax
je 0x429dcb
xor eax, eax
lea ecx, [ebp - 0x20]
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], eax
mov dword [ebp - 4], eax
mov dword [ebp - 0xc], 0xc
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
lea esi, [ebp - 0xc]
push 0
push 0
push 0
push 2
push esi
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, eax
call edi
test esi, esi
jne 0x429e0b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [ebp + 0xc]
push eax
push edx
push str.uprv_mapFile:_CreateFileMapping_failed_for__s___d__n
call fcn.00412850
add esp, 0xc
pop edi
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push 0
push 0
push 4
push esi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebx + 4], eax
test eax, eax
jne 0x429e45
push esi
call edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [ebp + 0xc]
push eax
push str.uprv_mapFile:_MapViewOfFile_failed_for__s___d__n
call fcn.00412850
add esp, 0xc
pop edi
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
mov dword [ebx + 0x14], esi
pop esi
mov al, 1
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4309d0
Capabilities:
Connect to wmi namespace via wbemlocator

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
cmp dword [ebp + 8], 0
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
jne 0x430a04
push str.nameSpace
push str.WMI_ConnectToWMI:__s_failed
push 1
call fcn.004303a0
add esp, 0xc
xor al, al
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
test eax, eax
jne 0x430a12
push str.servicesResult
jmp 0x4309ef
push esi
mov dword [eax], 0
lea eax, [ebp - 4]
push eax
push 0x45fe04
push 1
push 0
push 0x45fed4
call dword [sym.imp.ole32.dll_CoCreateInstance]
mov esi, eax
test esi, esi
jge 0x430a55
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push str.WMI_ConnectToWMI:_Could_not_create_namespace_locator:_0x_08x_0x_08x
push 1
call fcn.004303a0
add esp, 0x10
xor al, al
pop esi
mov esp, ebp
pop ebp
ret
push edi
push str.WMI_ConnectToWMI:_created_namespace_locator
push 0x10
call fcn.004303a0
xor edi, edi
push edi
call fcn.0041d830
add esp, 0xc
cmp eax, 5
jne 0x430a81
push 1
call fcn.0041d830
add esp, 4
cmp eax, 1
jge 0x430a90
push 0
call fcn.0041d830
add esp, 4
cmp eax, 5
jle 0x430a95
mov edi, 0x80
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov esi, eax
test esi, esi
jne 0x430ac7
push str.WMI_ConnectToWMI:_Failed_to_allocate_string_for_namespace
push 1
call fcn.004303a0
mov eax, dword [ebp - 4]
mov edx, dword [eax]
add esp, 8
push eax
mov eax, dword [edx + 8]
call eax
pop edi
xor al, al
pop esi
mov esp, ebp
pop ebp
ret
push str.WMI_ConnectToWMI:_Connecting_to_WMI_server
push 0x20
call fcn.004303a0
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
add esp, 8
lea edx, [ebp - 8]
push edx
push 0
push 0
push edi
push 0
push 0
push 0
push esi
push eax
mov eax, dword [ecx + 0xc]
call eax
push esi
mov edi, eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov dword [ebp - 4], 0
test edi, edi
jge 0x430b4e
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp edi, 0x8004100e
jne 0x430b35
push str.WMI_ConnectToWMI:_Failed_to_connect_since_namespace_doesnt_exist
push 4
call fcn.004303a0
add esp, 8
pop edi
xor al, al
pop esi
mov esp, ebp
pop ebp
ret
push eax
push edi
push str.WMI_ConnectToWMI:_Failed_to_connect_to_namespace_server:_0x_08x_0x_08x
push 1
call fcn.004303a0
add esp, 0x10
pop edi
xor al, al
pop esi
mov esp, ebp
pop ebp
ret
push str.WMI_ConnectToWMI:_Connected_to_WMI_server
push 0x20
call fcn.004303a0
mov edi, dword [ebp - 8]
add esp, 8
call fcn.00430400
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
pop edi
mov dword [ecx], eax
mov al, 1
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x431860
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, dword [sym.imp.MSVCR90.dll_free]
push esi
mov esi, dword [ebp + 8]
cmp byte [esi + 4], 0
push edi
mov dword [ebp - 4], 0
je 0x4318d1
cmp dword [esi + 0xc], 0x46cf24
je 0x4318c8
mov eax, dword [esi + 8]
push 0xffffffffffffffff
push 0
push str..lck
push 0
push 0xffffffffffffffff
push eax
call fcn.0040ba80
push 0x7d0
mov edi, eax
mov eax, dword [esi + 0xc]
push 0
push eax
call fcn.0040c750
push 0x7d0
push edi
mov dword [ebp - 4], eax
call fcn.0040c9b0
push edi
call ebx
mov ecx, dword [esi + 0xc]
push ecx
call ebx
add esp, 0x34
mov dword [esi + 0xc], 0
jmp 0x4318fa
lea edx, [esi + 0xc]
push edx
call fcn.00418f80
add esp, 4
test eax, eax
je 0x4318fa
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 0x10
je 0x4318fa
call edi
cmp eax, 2
je 0x4318fa
call edi
mov dword [ebp - 4], eax
mov eax, dword [esi + 8]
push eax
call ebx
push esi
mov dword [esi], 0
mov dword [esi + 8], 0
call ebx
mov eax, dword [ebp - 4]
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x401020
Capabilities:
Read file on windows

Disassembly:
xor ebx, ebx
push ebx
call sub.kernel32.dll_GetModuleHandleA
push ebx
push 0x4010b6
push ebx
push 0x3e8
push ebx
call sub.user32.dll_DialogBoxParamA
push ebx
call sub.kernel32.dll_ExitProcess
push ebp
mov ebp, esp
add esp, 0xfffffffc
jmp 0x401093
push 0x400
push 0x403193
call sub.kernel32.dll_RtlZeroMemory
push 0
lea eax, [ebp - 4]
push eax
push 0x3ff
push 0x403193
push dword [0x40311f]
call sub.kernel32.dll_ReadFile
or eax, eax
jne 0x40105f
push 0x64
call sub.kernel32.dll_Sleep
jmp 0x401093
push dword [0x40318f]
call sub.user32.dll_GetWindowTextLengthA
push eax
push eax
push 0xb1
push dword [0x40318f]
call sub.user32.dll_SendMessageA
push 0x403193
push 0
push 0xc2
push dword [0x40318f]
call sub.user32.dll_SendMessageA
cmp dword [section..data], 0
jne 0x401028
push dword [0x40311f]
call sub.kernel32.dll_CloseHandle
push dword [0x403127]
call sub.kernel32.dll_CloseHandle
leave
ret 4

Function at 0x42e002
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
call 0x42e00c
nop
nop
nop
nop
pop eax
nop
nop
add eax, 0x403ac5
nop
sub eax, 0x403a6b
nop
nop
nop
nop
mov ebx, dword [eax]
nop
nop
mov ecx, dword [eax + 4]
nop
mov edx, dword [eax + 8]
nop
nop
nop
nop
nop
nop
xor dword [ebx], edx
nop
nop
nop
add ebx, 4
nop
cmp ebx, ecx
nop
nop
nop
nop
nop
nop
nop
jl 0x42e030
nop
nop
add eax, 0xc
nop
nop
nop
nop
nop
cmp dword [eax], 0
nop
jne 0x42e01e
nop
nop
nop
nop
popal
nop
nop
nop
nop
jmp fcn.00401219
Function at 0x4048ba
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
push edi
mov edi, dword [ebp + 0xc]
test eax, eax
jg 0x4048db
jl 0x4048d2
test edi, edi
jne 0x4048db
xor eax, eax
xor edx, edx
jmp 0x40499c
cmp dword [ebx + 0x38], 0
je 0x4048f0
push eax
push edi
push dword [ebp + 8]
call fcn.004049a2
jmp 0x40499c
mov eax, dword [ebx + 0x1c]
push esi
mov esi, edi
mov ecx, dword [eax]
test ecx, ecx
je 0x404937
mov eax, dword [ebx + 0x2c]
mov eax, dword [eax]
mov dword [ebp - 4], eax
test eax, eax
je 0x404937
cmp eax, edi
jb 0x404911
mov eax, edi
mov dword [ebp - 4], edi
push eax
push ecx
push dword [ebp + 8]
call fcn.00406b90
mov ecx, dword [ebp - 4]
add esp, 0xc
mov eax, dword [ebp + 8]
sub esi, ecx
add eax, ecx
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x2c]
sub dword [eax], ecx
mov eax, dword [ebx + 0x1c]
add dword [eax], ecx
jmp 0x40493d
mov eax, dword [ebp + 8]
mov dword [ebp - 4], eax
cmp dword [ebx + 0x4c], 0
je 0x404991
mov ecx, ebx
call fcn.00404116
mov ecx, dword [ebp - 4]
mov edx, esi
mov eax, 0xfff
cmp esi, eax
jbe 0x40497c
push dword [ebx + 0x4c]
push eax
push 1
push ecx
call fcn.0040d5dd
mov ecx, dword [ebp - 4]
sub esi, eax
add ecx, eax
add esp, 0x10
mov dword [ebp - 4], ecx
mov edx, esi
cmp eax, 0xfff
jne 0x404991
jmp 0x40494f
test edx, edx
je 0x404991
push dword [ebx + 0x4c]
push esi
push 1
push ecx
call fcn.0040d5dd
add esp, 0x10
sub esi, eax
mov edx, dword [ebp + 0x10]
sub edi, esi
mov eax, edi
sbb edx, 0
pop esi
pop edi
pop ebx
leave
ret 0xc

Function at 0x40636d
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4063ac
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4063ac
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4063ac
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x4063ac
cmp dword [ecx + 0x74], 0xe
jbe 0x4063ac
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x40a3c4
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.004064e0
mov eax, dword [0x431014]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.004126b2
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x40a406
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x40a562
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.00422010
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x432808]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.004128c1
mov ecx, dword [esi*4 + 0x432808]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x40a55b
cmp eax, dword [ecx + edi + 0x24]
jne 0x40a55b
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40a55b
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004128c1
add esp, 0x14
test edx, edx
jl 0x40a55b
jg 0x40a4d1
test eax, eax
jb 0x40a55b
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x40a55b
jl 0x40a4eb
cmp dword [ebp - 0x1008], eax
ja 0x40a55b
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x40a509
test ebx, ebx
je 0x40a542
cmp ecx, edi
jae 0x40a542
mov al, byte [ecx]
cmp al, 0xd
jne 0x40a523
lea eax, [edi - 1]
cmp ecx, eax
jae 0x40a52f
cmp byte [ecx + 1], 0xa
jne 0x40a52f
inc ecx
jmp 0x40a52f
movzx eax, al
movsx eax, byte [eax + 0x431250]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x40a509
cmp edx, ebx
jne 0x40a509
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x40a560
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004056a7
leave
ret
Function at 0x412f66
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x432808]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x412fa6
cmp byte [ebx], 0xa
jne 0x412fa6
or byte [edi + eax + 0x28], 4
jmp 0x412fab
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x4130aa
mov dl, byte [eax]
cmp dl, 0x1a
je 0x41308d
inc eax
cmp dl, 0xd
je 0x412fd7
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x412ffd
cmp eax, ecx
jae 0x41300b
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x412fbf
jmp 0x4130aa
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x413088
cmp dword [ebp - 0x10], 0
je 0x413088
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x432808]
test byte [eax + edi + 0x28], 0x48
je 0x413062
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x41304d
mov byte [esi], dl
jmp 0x41305e
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x432808]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x4130aa
cmp byte [ebp - 1], 0xa
jne 0x413071
cmp esi, ebx
jne 0x413071
mov byte [esi], 0xa
jmp 0x4130a9
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.004128df
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x4130aa
mov byte [esi], 0xd
jmp 0x4130a9
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x432808]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x4130a7
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x4130aa
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret