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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x556d9b
mov eax, dword fs:[0]
push eax
sub esp, 0x2d8
mov eax, dword [0x5aa464]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x2dc], ecx
mov ebx, dword [ebp + 8]
mov dword [ebp - 0x2c8], ebx
call fcn.0045a210
push eax
lea ecx, [ebp - 0x94]
call fcn.00453bb0
mov dword [ebp - 4], 0
call fcn.0045a220
mov ecx, eax
call fcn.004547e0
mov esi, dword [sym.imp.KERNEL32.dll_GetFileSize]
test al, al
je 0x4a41b5
push ebx
lea ecx, [ebp - 0x94]
call fcn.00453fc0
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
lea ecx, [ebp - 0x94]
call fcn.0054d150
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x4a4139
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], eax
call fcn.00453d00
jmp 0x4a43e4
push 0
push ebx
call esi
mov esi, eax
test esi, esi
jne 0x4a415b
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43de
push esi
mov dword [ebp - 0x2cc], 0
call fcn.0050a1a4
add esp, 4
mov edi, eax
lea eax, [ebp - 0x2cc]
push 0
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x2cc], esi
je 0x4a43c4
push edi
call fcn.00509e61
add esp, 4
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43de
call fcn.0045a4e0
test al, al
jne 0x4a42d2
call fcn.0045a220
push eax
lea ecx, [ebp - 0x94]
call fcn.00453fa0
call fcn.0045a490
test al, al
je 0x4a41e3
call fcn.0045a230
jmp 0x4a41fb
push 2
push 0
lea ecx, [ebp - 0x94]
call fcn.0054d150
push eax
call fcn.004712b0
add esp, 0xc
mov ebx, eax
test ebx, ebx
jne 0x4a4218
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43e4
lea eax, [ebp - 0x2c4]
push eax
lea eax, [ebp - 0x2d4]
push eax
push 1
push dword [ebp - 0x2c8]
push ebx
call fcn.00470bc0
add esp, 0x14
test eax, eax
je 0x4a4252
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43e4
mov esi, dword [ebp - 0x98]
test esi, esi
jne 0x4a4273
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43de
push esi
call fcn.0050a1a4
push 3
push esi
mov edi, eax
push edi
push dword [ebp - 0x2d4]
push ebx
call fcn.00471740
add esp, 0x18
test eax, eax
je 0x4a42ba
cmp eax, 0x600
je 0x4a42ba
push edi
call fcn.00509e61
add esp, 4
call fcn.0045a490
test al, al
jne 0x4a419e
push ebx
call fcn.004709a0
jmp 0x4a419b
call fcn.0045a490
test al, al
jne 0x4a43c4
push ebx
call fcn.004709a0
jmp 0x4a43c1
call fcn.0045a220
push eax
lea ecx, [ebp - 0x94]
call fcn.00453fa0
call fcn.0045a490
test al, al
je 0x4a42f3
call fcn.0045a230
jmp 0x4a430b
push 0
push 0
lea ecx, [ebp - 0x94]
call fcn.0054d150
push eax
call fcn.00475760
add esp, 0xc
mov ebx, eax
test ebx, ebx
jne 0x4a4328
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43e4
lea eax, [ebp - 0x2e4]
push eax
lea eax, [ebp - 0x2d8]
push eax
push dword [ebp - 0x2c8]
push ebx
call fcn.00475060
add esp, 0x10
test eax, eax
je 0x4a4360
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
jmp 0x4a43e4
mov esi, dword [ebp - 0x2e4]
test esi, esi
je 0x4a419e
push esi
call fcn.0050a1a4
mov edi, eax
push edi
push dword [ebp - 0x2d8]
push ebx
call fcn.004759d0
add esp, 0x10
test eax, eax
je 0x4a43b2
cmp eax, 0x600
je 0x4a43b2
push edi
call fcn.00509e61
add esp, 4
call fcn.0045a490
test al, al
jne 0x4a419e
push ebx
call fcn.00474f70
jmp 0x4a419b
call fcn.0045a490
test al, al
jne 0x4a43c4
push ebx
call fcn.00474f70
add esp, 4
lea ecx, [ebp - 0x94]
mov dword [ebp - 4], 0xffffffff
call fcn.00453d00
test edi, edi
jne 0x4a445f
mov esi, dword [sym.imp.KERNEL32.dll_GetFileSize]
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
push dword [ebp - 0x2c8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4a445b
push 0
push ebx
call esi
mov esi, eax
test esi, esi
je 0x4a445b
push esi
mov dword [ebp - 0x2d0], 0
call fcn.0050a1a4
add esp, 4
mov edi, eax
lea eax, [ebp - 0x2d0]
push 0
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x2d0], esi
je 0x4a4457
push edi
call fcn.00509e61
add esp, 4
xor eax, eax
jmp 0x4a447b
test edi, edi
jne 0x4a445f
xor eax, eax
jmp 0x4a447b
mov ecx, dword [ebp - 0x2dc]
push esi
push edi
call fcn.004a44a0
push 1
push edi
mov esi, eax
call fcn.00509bb8
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00509b84
mov esp, ebp
pop ebp
ret 4