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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x44c
mov eax, dword [0x10285008]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x43c], ecx
mov eax, edx
mov ecx, dword [ebp + 0xc]
push ebx
mov dword [ebp - 0x420], ecx
mov ecx, dword [ebp + 0x10]
push esi
mov dword [ebp - 0x428], ecx
mov ecx, dword [ebp + 0x14]
push edi
mov dword [ebp - 0x42c], ecx
lea ecx, [ebp - 0x448]
push ecx
push eax
mov dword [ebp - 0x41c], eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x101718d7
mov esi, 0x8000ffff
jmp 0x10171b11
mov esi, dword [ebp - 0x448]
push 0x1008c6fc
push esi
call fcn.102364fd
mov edi, eax
pop ecx
pop ecx
test edi, edi
jne 0x101718fa
mov esi, 0x8007000e
jmp 0x10171b11
xor eax, eax
push eax
push eax
push eax
push dword [ebp - 0x41c]
mov ebx, eax
mov dword [ebp - 0x438], eax
mov dword [ebp - 0x430], eax
mov dword [ebp - 0x424], ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x10171a66
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x1008c008
call fcn.100d3aab
pop ecx
pop ecx
mov esi, 0x8000ffff
push edi
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete_void__]
pop ecx
test esi, esi
js 0x10171b11
xor eax, eax
push 0x40e
push eax
mov word [ebp - 0x418], ax
lea eax, [ebp - 0x416]
push eax
call sub.msvcrt.dll_memset
mov ecx, dword [ebp - 0x42c]
xor edx, edx
mov eax, dword [ebx]
add esp, 0xc
mov edi, edx
mov dword [ecx], eax
test eax, eax
je 0x10171b09
mov ecx, dword [ebp - 0x428]
lea eax, [ebx + 4]
sub ecx, dword [ebp - 0x420]
mov dword [ebp - 0x424], eax
mov dword [ebp - 0x428], ecx
cmp edi, 0x10
jae 0x10171b09
test esi, esi
js 0x10171b09
mov ecx, edx
mov dword [ebp - 0x41c], edx
cmp edi, dword [ebx]
jae 0x101719be
mov ecx, dword [eax]
lea edx, [ebp - 0x41c]
call fcn.101717d2
mov esi, eax
test esi, esi
js 0x10171ac0
mov eax, dword [ebp - 0x420]
add eax, dword [ebp - 0x428]
mov ecx, dword [ebp - 0x43c]
push eax
push 0x208
lea eax, [ebp - 0x418]
push eax
push dword [ebp - 0x41c]
call fcn.102146a9
mov esi, eax
test esi, esi
jne 0x10171acb
lea ecx, [ebp - 0x418]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0x438]
jne 0x10171a10
sub ecx, edx
sar ecx, 1
push 0x1008c6fc
push 2
pop edx
lea eax, [ecx + 1]
xor ecx, ecx
mov dword [ebp - 0x434], eax
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.102364fd
pop ecx
pop ecx
mov ecx, eax
mov eax, dword [ebp - 0x420]
mov dword [eax], ecx
test ecx, ecx
jne 0x10171aa8
push 0x1008c5b0
call fcn.100d3aab
mov esi, 0x8007000e
jmp 0x10171aca
xor eax, eax
push eax
lea eax, [ebp - 0x430]
push eax
push esi
push edi
push dword [ebp - 0x41c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [ebp - 0x430]
cmp edx, esi
jne 0x1017193b
lea eax, [ebp - 0x424]
push eax
push ecx
mov ecx, edi
call fcn.10234f37
mov ebx, dword [ebp - 0x424]
mov esi, eax
jmp 0x10171940
lea eax, [ebp - 0x418]
push eax
push dword [ebp - 0x434]
push ecx
call fcn.10236bda
add esp, 0xc
jmp 0x10171acb
push 0x1008c608
call fcn.100d3aab
pop ecx
cmp dword [ebp - 0x41c], 0
je 0x10171ae1
push dword [ebp - 0x41c]
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete_void__]
pop ecx
mov ecx, dword [ebp - 0x42c]
inc edi
mov eax, dword [ebp - 0x424]
add dword [ebp - 0x420], 4
add eax, 4
push 0
mov dword [ebp - 0x424], eax
pop edx
cmp edi, dword [ecx]
jb 0x1017199f
push ecx
mov ecx, ebx
call fcn.102350f8
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10236010
mov esp, ebp
pop ebp
ret 0x10