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

Disassembly:
jmp 0x46076f
push 0x72c
mov eax, 0x524550
call fcn.00407194
mov esi, dword [ebp + 8]
lea ecx, [ebp - 0x4f8]
call fcn.00405b14
xor edi, edi
lea ecx, [ebp - 0x4f8]
push edi
push edi
push esi
mov dword [ebp - 4], edi
call fcn.00402a9a
lea eax, [ebp - 0x3f0]
push eax
lea ecx, [ebp - 0x19c]
call fcn.004016e5
mov byte [ebp - 4], 1
mov esi, edi
mov ebx, edi
call fcn.0040904d
push eax
lea ecx, [ebp - 0x94]
call fcn.004016e5
mov byte [ebp - 4], 2
call fcn.00401893
mov ecx, eax
call fcn.004029c8
test al, al
je 0x46088b
lea eax, [ebp - 0x19c]
push eax
lea ecx, [ebp - 0x94]
call fcn.004048ae
push edi
push 0x80
push 3
push edi
push 1
push SysReAllocString
lea ecx, [ebp - 0x94]
call fcn.004090bb
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x72c], eax
cmp eax, 0xffffffff
jne 0x460835
lea ecx, [ebp - 0x94]
mov byte [ebp - 4], 1
call fcn.00401dd4
jmp 0x460a22
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x460821
push ebx
mov dword [ebp - 0x734], edi
call fcn.00403e68
pop ecx
push edi
mov esi, eax
lea eax, [ebp - 0x734]
push eax
push ebx
push esi
push dword [ebp - 0x72c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x72c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x734], ebx
je 0x460a0b
push esi
call fcn.00405e4d
pop ecx
mov esi, edi
jmp 0x460821
call fcn.00401893
push eax
lea ecx, [ebp - 0x94]
call fcn.004048ae
call fcn.00406feb
test al, al
je 0x4608b2
call fcn.0040228e
mov dword [ebp - 0x72c], eax
jmp 0x460921
call fcn.0040302b
push eax
lea ecx, [ebp - 0x220]
call fcn.004016e5
push edi
lea ecx, [ebp - 0x220]
mov byte [ebp - 4], 3
call fcn.004090bb
push eax
call fcn.0046fa10
pop ecx
pop ecx
push eax
lea ecx, [ebp - 0x94]
mov dword [ebp - 0x730], eax
call fcn.004090bb
push eax
call fcn.004019d3
mov dword [ebp - 0x72c], eax
mov eax, dword [ebp - 0x730]
pop ecx
pop ecx
test eax, eax
je 0x46090c
push eax
call fcn.00405e4d
pop ecx
lea ecx, [ebp - 0x220]
mov byte [ebp - 4], 2
call fcn.00401dd4
mov eax, dword [ebp - 0x72c]
test eax, eax
je 0x460821
lea eax, [ebp - 0x19c]
mov dword [ebp - 0x738], edi
push eax
lea ecx, [ebp - 0x118]
call fcn.004016e5
push 0x5335ac
push 0x535818
lea ecx, [ebp - 0x118]
mov byte [ebp - 4], 4
call fcn.00403ef4
lea eax, [ebp - 0x728]
push eax
lea eax, [ebp - 0x738]
push eax
push 1
lea ecx, [ebp - 0x118]
call fcn.0040662c
push eax
push dword [ebp - 0x72c]
call fcn.00407da1
add esp, 0x14
test eax, eax
je 0x460998
lea ecx, [ebp - 0x118]
call fcn.00401dd4
jmp 0x460821
mov ebx, dword [ebp - 0x4fc]
test ebx, ebx
je 0x460988
push ebx
call fcn.00403e68
push ebx
mov esi, eax
push esi
push dword [ebp - 0x738]
push dword [ebp - 0x72c]
call fcn.00401e42
add esp, 0x14
test eax, eax
je 0x4609eb
cmp eax, 0x600
je 0x4609eb
push esi
call fcn.00405e4d
pop ecx
mov esi, edi
call fcn.00406feb
test al, al
jne 0x460988
push dword [ebp - 0x72c]
call fcn.0040380f
pop ecx
jmp 0x460988
call fcn.00406feb
test al, al
jne 0x460a00
push dword [ebp - 0x72c]
call fcn.0040380f
pop ecx
lea ecx, [ebp - 0x118]
call fcn.00401dd4
lea ecx, [ebp - 0x94]
mov byte [ebp - 4], 1
call fcn.00401dd4
test esi, esi
jne 0x460aa3
push edi
push 0x80
push 3
push edi
push 1
push SysReAllocString
lea ecx, [ebp - 0x19c]
call fcn.0040662c
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x72c], eax
cmp eax, 0xffffffff
je 0x460a9f
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x460a9f
push ebx
mov dword [ebp - 0x730], edi
call fcn.00403e68
pop ecx
push edi
mov esi, eax
lea eax, [ebp - 0x730]
push eax
push ebx
push esi
push dword [ebp - 0x72c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x72c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x730], ebx
je 0x460a9f
push esi
call fcn.00405e4d
pop ecx
jmp 0x460ab5
test esi, esi
je 0x460ab5
push ebx
push esi
call fcn.00405d44
push esi
mov edi, eax
call fcn.00405e4d
add esp, 0xc
lea ecx, [ebp - 0x19c]
call fcn.00401dd4
lea ecx, [ebp - 0x4f8]
call fcn.004038a0
mov eax, edi
call fcn.00408fda
ret