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

Disassembly:
push 0x3dc
mov eax, 0x538695
call fcn.00500c07
mov dword [ebp - 0x3e8], ecx
xor esi, esi
lea ecx, [ebp - 0x9c]
push 0x58ab80
mov edi, esi
mov ebx, esi
call fcn.0047ce33
mov dword [ebp - 4], esi
mov eax, dword [0x58ac18]
cmp word [eax], si
jne 0x4a772d
mov eax, dword [ebp - 0x3e8]
test eax, eax
je 0x4a769c
push eax
lea ecx, [ebp - 0x9c]
call fcn.0047ce68
push esi
push pe_nt_image_headers32
push 3
push esi
push 1
push SysReAllocString
push dword [ebp - 0x9c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x3e0], eax
cmp eax, 0xffffffff
jne 0x4a76d7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x9c]
call fcn.0047ce58
jmp 0x4a78a6
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x4a76c3
push ebx
mov dword [ebp - 0x3e4], esi
call fcn.005008e0
pop ecx
push esi
mov edi, eax
lea eax, [ebp - 0x3e4]
push eax
push ebx
push edi
push dword [ebp - 0x3e0]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x3e0]
call dword [0x53e34c]
cmp dword [ebp - 0x3e4], ebx
je 0x4a7893
push edi
call fcn.005005bb
pop ecx
mov edi, esi
jmp 0x4a76c3
push eax
lea ecx, [ebp - 0x9c]
call fcn.0047ce68
cmp byte [0x58aad9], 0
je 0x4a774f
mov eax, dword [0x58ee64]
mov dword [ebp - 0x3e0], eax
jmp 0x4a77ae
push 0x58acb0
lea ecx, [ebp - 0x1ac]
call fcn.0047ce33
mov byte [ebp - 4], 1
mov ecx, dword [ebp - 0x1ac]
call fcn.00485466
mov ecx, dword [ebp - 0x9c]
xor edx, edx
push eax
push 2
mov dword [ebp - 0x3e4], eax
call fcn.004bd47d
mov dword [ebp - 0x3e0], eax
mov eax, dword [ebp - 0x3e4]
pop ecx
pop ecx
test eax, eax
je 0x4a779d
push eax
call fcn.005005bb
pop ecx
lea ecx, [ebp - 0x1ac]
call fcn.0047ce58
mov eax, dword [ebp - 0x3e0]
test eax, eax
je 0x4a76c3
push 0xffffffffffffffff
push dword [ebp - 0x3e8]
lea ecx, [ebp - 0x124]
mov dword [ebp - 0x3e4], esi
call fcn.0047ce0f
push 0x557934
push 0x557034
lea ecx, [ebp - 0x124]
mov byte [ebp - 4], 2
call fcn.0047d279
mov edx, dword [ebp - 0x124]
lea eax, [ebp - 0x3dc]
push eax
lea eax, [ebp - 0x3e4]
push eax
push ecx
mov ecx, dword [ebp - 0x3e0]
call fcn.004bd4f7
add esp, 0xc
test eax, eax
je 0x4a781f
lea ecx, [ebp - 0x124]
call fcn.0047ce58
jmp 0x4a76c3
mov ebx, dword [ebp - 0x1b0]
test ebx, ebx
je 0x4a780f
push ebx
call fcn.005008e0
mov edx, dword [ebp - 0x3e4]
mov edi, eax
pop ecx
mov ecx, dword [ebp - 0x3e0]
push 3
push ebx
push edi
call fcn.004bd52a
add esp, 0xc
test eax, eax
je 0x4a7874
cmp eax, 0x600
je 0x4a7874
push edi
call fcn.005005bb
cmp byte [0x58aad9], 0
mov edi, esi
pop ecx
jne 0x4a780f
mov ecx, dword [ebp - 0x3e0]
call fcn.004bd55d
jmp 0x4a780f
cmp byte [0x58aad9], 0
jne 0x4a7888
mov ecx, dword [ebp - 0x3e0]
call fcn.004bd55d
lea ecx, [ebp - 0x124]
call fcn.0047ce58
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x9c]
call fcn.0047ce58
test edi, edi
jne 0x4a7918
push esi
push pe_nt_image_headers32
push 3
push esi
push 1
push SysReAllocString
push dword [ebp - 0x3e8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x3e8], eax
cmp eax, 0xffffffff
je 0x4a7914
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x4a7914
push ebx
mov dword [ebp - 0x3e0], esi
call fcn.005008e0
pop ecx
push esi
mov edi, eax
lea eax, [ebp - 0x3e0]
push eax
push ebx
push edi
push dword [ebp - 0x3e8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x3e8]
call dword [0x53e34c]
cmp dword [ebp - 0x3e0], ebx
jne 0x4a7923
test edi, edi
je 0x4a792a
mov edx, ebx
mov ecx, edi
call fcn.004a7932
mov esi, eax
push edi
call fcn.005005bb
pop ecx
mov eax, esi
call fcn.00500bc5
ret