Function at 0x422900
Capabilities:
Read file on windows

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x486331
push eax
mov dword fs:[0], esp
sub esp, 0x154
push ebx
push ebp
push esi
mov esi, ecx
push edi
cmp byte [esi + 0x10], 0xdb
je 0x422934
xor edi, edi
push edi
call fcn.004223f0
add esp, 4
jmp 0x422936
xor edi, edi
mov eax, dword [esi + 0x14]
cmp eax, edi
je 0x422950
mov cl, byte [esi + 0x11]
test cl, cl
jne 0x42294d
push eax
call fcn.0046f89f
add esp, 4
mov dword [esi + 0x14], edi
lea ecx, [esp + 0x54]
mov dword [esi + 0x18], edi
mov dword [esi + 0x1c], edi
mov byte [esi + 0x11], 0
call fcn.0041c6f0
mov eax, dword [esp + 0x174]
lea ecx, [esp + 0x54]
push eax
mov dword [esp + 0x170], edi
call fcn.0041c980
mov ebp, dword [esp + 0x178]
lea ecx, [esp + 0x20]
push ebp
lea edx, [esp + 0x58]
push ecx
push edx
call fcn.0041edf0
mov ebx, eax
add esp, 0xc
cmp ebx, 0xffffffff
je 0x422a7e
push ebp
push ebx
call fcn.0041fcd0
mov edi, edx
xor ecx, ecx
add esp, 8
cmp edi, ecx
mov dword [esp + 0x24], eax
jg 0x4229c2
jl 0x4229bc
cmp eax, ecx
jae 0x4229c2
push ecx
jmp 0x422a75
mov edx, eax
or edx, edi
jne 0x4229ed
push ecx
push ebx
call fcn.00449e50
add esp, 8
lea ecx, [esp + 0x54]
mov dword [esp + 0x16c], 0xffffffff
call fcn.0041c7c0
mov al, 1
jmp 0x422bdd
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], ecx
lea ecx, [esp + 0x18]
lea edx, [esp + 0x14]
push ecx
push edx
push edi
push eax
call fcn.0044ae60
mov eax, dword [esp + 0x28]
add esp, 0x10
test eax, eax
jbe 0x422a37
test ebp, ebp
je 0x422a73
mov eax, dword [ebp]
push str.Out_of_memory_for_data_buffer
mov ecx, ebp
call dword [eax + 0x10]
mov eax, dword [esp + 0x24]
mov edx, dword [ebp]
push edi
push eax
push str.fileSize
mov ecx, ebp
call dword [edx + 0x30]
jmp 0x422a73
mov ecx, dword [esp + 0x14]
add ecx, 4
push ecx
call fcn.0046fd5a
mov edx, eax
add esp, 4
test edx, edx
mov dword [esi + 0x14], edx
jne 0x422a99
test ebp, ebp
je 0x422a73
mov edx, dword [ebp]
push str.Out_of_memory
mov ecx, ebp
call dword [edx + 0x10]
mov ecx, dword [esp + 0x14]
mov eax, dword [ebp]
push ecx
push str.fileSize
mov ecx, ebp
call dword [eax + 0x2c]
push 0
push ebx
call fcn.00449e50
add esp, 8
lea ecx, [esp + 0x54]
mov dword [esp + 0x16c], 0xffffffff
call fcn.0041c7c0
xor al, al
jmp 0x422bdd
mov eax, dword [esp + 0x14]
mov edi, edx
push 0
lea ecx, [eax + 4]
xor eax, eax
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
lea edx, [esp + 0x20]
and ecx, 3
push edx
rep stosb byte es:[edi], al
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x24], 0
mov dword [esi + 0x18], eax
push eax
lea ecx, [eax + 4]
mov eax, dword [esi + 0x14]
push eax
push ebx
mov dword [esi + 0x1c], ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
mov byte [esp + 0x13], 1
jne 0x422b98
test ebp, ebp
je 0x422b93
lea ecx, [esp + 0x2c]
call fcn.00419150
lea ecx, [esp + 0x2c]
mov byte [esp + 0x16c], 1
call fcn.0041a6e0
mov esi, dword [ebp]
lea ecx, [esp + 0x2c]
call fcn.004220a0
push eax
mov ecx, ebp
call dword [esi + 0x10]
mov eax, dword [esp + 0x174]
mov edx, dword [ebp]
push eax
push str.filename
mov ecx, ebp
call dword [edx + 0x28]
lea ecx, [esp + 0xdc]
call fcn.0041c6f0
lea ecx, [esp + 0xdc]
mov byte [esp + 0x16c], 2
push ecx
call fcn.0041dbd0
mov esi, dword [ebp]
add esp, 4
lea ecx, [esp + 0xdc]
call fcn.0041cff0
push eax
push str.current_dir
mov ecx, ebp
call dword [esi + 0x28]
lea ecx, [esp + 0xdc]
mov byte [esp + 0x16c], 1
call fcn.0041c7c0
lea ecx, [esp + 0x2c]
mov byte [esp + 0x16c], 0
call fcn.00419440
mov byte [esp + 0x13], 0
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
cmp edx, eax
je 0x422bba
test ebp, ebp
je 0x422bb5
mov eax, dword [ebp]
push str.Failed_to_read_the_entire_file
mov ecx, ebp
call dword [eax + 0x10]
mov byte [esp + 0x13], 0
push 0
push ebx
call fcn.00449e50
add esp, 8
lea ecx, [esp + 0x54]
mov dword [esp + 0x16c], 0xffffffff
call fcn.0041c7c0
mov al, byte [esp + 0x13]
mov ecx, dword [esp + 0x164]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x160
ret 8