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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x650b48
mov eax, dword fs:[0]
push eax
sub esp, 0x30
mov eax, dword [0x6e1c7c]
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 ebx, ecx
mov eax, dword [ebx]
mov esi, dword [ebp + 8]
test eax, eax
je 0x4f925f
push eax
call fcn.0062208a
add esp, 4
mov eax, dword [ebx + 4]
test eax, eax
je 0x4f926f
push eax
call fcn.0062208a
add esp, 4
push 0x6e2a98
lea ecx, [ebp - 0x28]
mov dword [ebx], 0
mov dword [ebx + 4], 0
call fcn.00456990
push esi
mov dword [ebp - 4], 0
call dword [sym.imp.SHLWAPI.dll_PathIsRelativeW]
mov ecx, esi
lea edx, [ecx + 2]
test eax, eax
je 0x4f92c0
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4f92a0
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x28]
call fcn.0044e880
jmp 0x4f92d9
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4f92c0
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x28]
call fcn.0044e410
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
push 0
cmovae eax, dword [ebp - 0x28]
push 0x80
push 3
push 0
push 1
push bind
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x30], eax
cmp eax, 0xffffffff
jne 0x4f930e
push 0x63
push 0x6bea38
jmp 0x4f9385
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
mov dword [ebp - 0x38], esi
test esi, esi
jne 0x4f9329
push 0x63
push str.File_is_empty
jmp 0x4f9385
cmp esi, 0x400000
jbe 0x4f933a
push 0x63
push str.File_too_large
jmp 0x4f9385
push esi
mov dword [ebp - 0x34], 0
call fcn.006026e6
add esp, 4
mov edi, eax
lea eax, [ebp - 0x34]
mov dword [ebp - 0x3c], edi
push 0
push eax
push esi
push edi
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x34], esi
je 0x4f93ab
push edi
call fcn.0060224c
add esp, 4
mov ecx, ebx
call fcn.004f94c0
push 0x63
push str.Could_not_read_file
lea eax, [ebx + 0x10]
push eax
call fcn.0062f135
push 0x31
lea eax, [ebx + 0xd8]
push 0x6b4dbc
push eax
call fcn.0062f135
add esp, 0x18
xor bl, bl
jmp 0x4f945c
mov eax, edi
mov dword [ebp - 0x30], eax
cmp esi, 3
jb 0x4f93d2
cmp byte [edi], 0xef
jne 0x4f93d2
cmp byte [edi + 1], 0xbb
jne 0x4f93d2
cmp byte [edi + 2], 0xbf
jne 0x4f93d2
lea eax, [edi + 3]
add esi, 0xfffffffd
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x38], esi
mov edi, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push 0
push 0
push esi
push eax
push 0
push 0xfde9
call edi
mov esi, eax
lea ecx, [esi*2 + 2]
push ecx
call fcn.006238cb
add esp, 4
mov dword [ebx], eax
push esi
push eax
push dword [ebp - 0x38]
push dword [ebp - 0x30]
push 0
push 0xfde9
call edi
mov eax, dword [ebx]
xor ecx, ecx
mov word [eax + esi*2], cx
mov ecx, ebx
call fcn.004f9500
mov byte [ebp - 0x29], al
test al, al
jne 0x4f944e
mov eax, dword [ebx]
test eax, eax
je 0x4f9431
push eax
call fcn.0062208a
add esp, 4
mov eax, dword [ebx + 4]
test eax, eax
je 0x4f9441
push eax
call fcn.0062208a
add esp, 4
mov dword [ebx], 0
mov dword [ebx + 4], 0
push dword [ebp - 0x3c]
call fcn.0060224c
mov bl, byte [ebp - 0x29]
add esp, 4
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x4f9492
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x4f9488
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4f94b2
push edx
push ecx
call fcn.0060223e
add esp, 8
mov al, bl
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.006021fd
mov esp, ebp
pop ebp
ret 8
call fcn.00621ffe
int3