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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
push edi
xor edi, edi
mov dword [ebp - 0xc], edi
mov dword [ebp - 8], edi
cmp dword [ebp + 0xc], edi
jne 0x4369d8
mov eax, 0x80070057
push eax
push 0x345
push str.fileutil.cpp
mov esi, eax
call fcn.0042fef9
jmp 0x436c58
mov eax, dword [ebp + 8]
test eax, eax
jne 0x4369ec
mov eax, 0x80070057
push eax
push 0x346
jmp 0x4369c7
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x436a00
mov eax, 0x80070057
push eax
push 0x347
jmp 0x4369c7
xor ecx, ecx
cmp cx, word [eax]
jne 0x436a14
mov eax, 0x80070057
push eax
push 0x348
jmp 0x4369c7
push ebx
push edi
push 0x8000080
push 3
push edi
push 5
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov dword [ebp - 4], esi
cmp esi, 0xffffffff
jne 0x436a82
call ebx
mov ecx, eax
movzx eax, cx
or eax, 0x80070000
test ecx, ecx
cmovle eax, ecx
mov esi, 0x80070002
cmp eax, esi
je 0x436c57
test ecx, ecx
je 0x436a7f
mov esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x352
push str.fileutil.cpp
call fcn.0042fef9
jmp 0x436c57
mov esi, dword [ebp - 4]
lea eax, [ebp - 0xc]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x436ac0
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x357
push str.fileutil.cpp
call fcn.0042fef9
jmp 0x436c48
cmp dword [ebp + 0x14], edi
je 0x436b0c
mov edi, dword [ebp + 0x18]
xor eax, eax
cmp eax, dword [ebp - 8]
jl 0x436ae0
jg 0x436ad6
cmp edi, dword [ebp - 0xc]
jbe 0x436ae0
mov esi, 0x80070057
jmp 0x436c48
push 1
push eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x436b0c
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
jns 0x436b0c
push esi
push 0x365
jmp 0x436ab1
cmp dword [ebp + 0x20], 0
je 0x436b38
mov ebx, dword [ebp + 0x1c]
xor edi, edi
mov esi, dword [ebp + 8]
cmp dword [esi], 0
je 0x436b86
test ebx, ebx
jne 0x436b64
push dword [esi]
call fcn.00430f57
mov dword [esi], edi
mov eax, dword [ebp + 0xc]
mov esi, edi
mov dword [eax], edi
jmp 0x436c48
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
mov ebx, ecx
sub ebx, edi
sub ecx, edi
push 0
pop edi
sbb eax, edi
cmp edi, eax
jg 0x436b17
jl 0x436b54
cmp dword [ebp + 0x1c], ecx
jae 0x436b17
mov esi, 0x8007007a
push esi
push 0x377
jmp 0x436ab1
push 1
push ebx
push dword [esi]
call fcn.0043102c
mov edi, eax
test edi, edi
jne 0x436baa
mov eax, 0x8007000e
push eax
mov esi, eax
push 0x385
jmp 0x436ab1
test ebx, ebx
je 0x436b2c
push 1
push ebx
call fcn.00430e98
mov edi, eax
test edi, edi
jne 0x436baa
mov eax, 0x8007000e
push eax
mov esi, eax
push 0x392
jmp 0x436ab1
xor ecx, ecx
mov eax, ecx
mov dword [ebp + 0x1c], eax
mov dword [ebp + 0x10], ecx
jmp 0x436bb8
xor ecx, ecx
mov dword [ebp + 0x14], ecx
lea ecx, [ebp + 0x14]
push ecx
push eax
push ebx
call fcn.00430069
mov esi, eax
test esi, esi
js 0x436c3e
mov ecx, dword [ebp + 0x1c]
push 0
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0x14]
add ecx, edi
push ecx
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x436c10
mov eax, dword [ebp + 0x1c]
add eax, dword [ebp + 0x10]
cmp dword [ebp + 0x10], 0
mov dword [ebp + 0x1c], eax
jne 0x436bb6
cmp eax, ebx
je 0x436c02
mov esi, 0x8000ffff
jmp 0x436c3e
mov eax, dword [ebp + 8]
mov dword [eax], edi
mov eax, dword [ebp + 0xc]
xor edi, edi
mov dword [eax], ebx
jmp 0x436c3e
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
mov eax, 0x80004005
test esi, esi
cmovns esi, eax
push esi
push 0x39f
push str.fileutil.cpp
call fcn.0042fef9
test edi, edi
je 0x436c48
push edi
call fcn.00430f57
mov eax, dword [ebp - 4]
cmp eax, 0xffffffff
je 0x436c57
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, esi
pop esi
leave
ret 0x1c