Function at 0x4070f9
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov dword [ebp - 0x1c], ecx
cmp dword [ebp + 8], 0
jne 0x407137
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x1c]
add ecx, 0x105
push ecx
call fcn.00409b30
add esp, 8
push 0x425764
mov edx, dword [ebp - 0x1c]
add edx, 0x105
push edx
call fcn.00409b40
add esp, 8
jmp 0x40716a
mov eax, dword [ebp + 8]
push eax
call fcn.00409ab0
add esp, 4
cmp eax, 0x104
jbe 0x407154
mov eax, 0xfffffffe
jmp 0x407372
mov ecx, dword [ebp + 8]
push ecx
mov edx, dword [ebp - 0x1c]
add edx, 0x105
push edx
call fcn.00409b30
add esp, 8
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 0x418]
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp - 0x14]
push edx
call fcn.00416749
add esp, 4
mov eax, dword [ebp - 0x1c]
mov dword [eax + 0x418], 0
mov ecx, dword [ebp - 0x1c]
mov dword [ecx + 0x414], 0
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
mov edx, dword [ebp - 0x1c]
add edx, 0x105
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
jne 0x4071d1
mov eax, 0xfffffffe
jmp 0x407372
lea eax, [ebp - 0xc]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 8], eax
cmp dword [ebp - 0xc], 0
jne 0x4071f7
cmp dword [ebp - 8], 0xffffffff
je 0x4071f7
cmp dword [ebp - 8], 0x100000
jbe 0x40720b
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 0xfffffffe
jmp 0x407372
mov eax, dword [ebp - 8]
add eax, 0x400
mov ecx, dword [ebp - 0x1c]
mov dword [ecx + 0x41c], eax
mov edx, dword [ebp - 0x1c]
cmp dword [edx + 0x41c], 0x100000
jle 0x407238
mov eax, dword [ebp - 0x1c]
mov dword [eax + 0x41c], 0x100000
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + 0x41c]
push edx
call fcn.00416720
add esp, 4
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x18]
mov dword [eax + 0x418], ecx
mov edx, dword [ebp - 0x1c]
cmp dword [edx + 0x418], 0
jne 0x407279
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 0xfffffffd
jmp 0x407372
push 0
mov ecx, dword [ebp - 0x1c]
add ecx, 0x420
push ecx
mov edx, dword [ebp - 8]
push edx
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 0x418]
push ecx
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 4], 0
je 0x4072be
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + 0x420]
cmp edx, dword [ebp - 8]
je 0x4072c8
mov eax, 0xfffffffe
jmp 0x407372
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + 0x418]
mov dword [eax + 0x414], edx
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 0x414]
mov edx, dword [ebp - 0x1c]
mov eax, dword [ecx + 0x18]
cmp eax, dword [edx + 0x420]
jl 0x4072f8
mov eax, 0xfffffffe
jmp 0x407372
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + 0x414]
cmp dword [edx + 0x18], 0
je 0x40731d
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 0x414]
cmp dword [ecx + 0x18], 0x1c
jge 0x40731d
mov eax, 0xfffffffe
jmp 0x407372
mov edx, dword [ebp - 0x1c]
mov eax, dword [edx + 0x414]
cmp dword [eax + 0x14], 0x1c
jl 0x407343
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + 0x414]
mov eax, dword [ebp - 0x1c]
mov ecx, dword [edx + 0x14]
cmp ecx, dword [eax + 0x420]
jle 0x40734a
mov eax, 0xfffffffe
jmp 0x407372
mov ecx, dword [ebp - 0x1c]
call fcn.0040753a
test eax, eax
je 0x40735d
mov eax, 0xfffffff9
jmp 0x407372
mov ecx, dword [ebp - 0x1c]
call fcn.004079c4
test eax, eax
je 0x407370
mov eax, 0xfffffffa
jmp 0x407372
xor eax, eax
mov esp, ebp
pop ebp
ret 4