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

Disassembly:
push 0xffffffffffffffff
push 0x10022fd8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x3c]
push ebx
push ebp
xor ebp, ebp
push esi
mov dword [eax], ebp
mov esi, dword [ecx + 4]
push 1
push ebp
push ebp
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x18], ebx
jne 0x100137bd
mov edx, dword [esp + 0x50]
pop esi
mov eax, 1
mov dword [edx], ebp
pop ebp
pop ebx
mov ecx, dword [esp + 0x2c]
mov dword fs:[0], ecx
add esp, 0x38
ret
push edi
push ebp
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
mov al, byte [esp + 0x54]
mov byte [esp + 0x2c], al
xor eax, eax
sub edi, ebx
mov dword [esp + 0x30], ebp
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], ebp
cmp edi, ebp
mov dword [esp + 0x44], ebp
mov dword [esp + 0x14], ebp
mov dword [esp + 0x20], ebp
jle 0x100139aa
mov ebx, edi
mov dword [esp + 0x18], ebx
jmp 0x10013800
mov ebx, dword [esp + 0x18]
push 0x1000
call sub.MSVCRT.dll_malloc
add esp, 4
mov dword [esp + 0x24], eax
push 1
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebp, eax
cmp ebx, 0x1000
mov eax, ebx
jl 0x1001382f
mov eax, 0x1000
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x10]
push 0
push ecx
push eax
push edx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x100138f4
mov eax, dword [esp + 0x4c]
xor ebx, ebx
mov edx, dword [eax + 0x130]
lea ecx, [eax + 0xc]
push ecx
mov ecx, dword [esp + 0x28]
add eax, 0x2c
push edx
push eax
mov eax, dword [esp + 0x1c]
push eax
push ecx
push ebp
call fcn.100160a0
mov ecx, dword [esp + 0x28]
add esp, 0x18
xor eax, eax
test ecx, ecx
jbe 0x100138a2
mov edx, dword [esp + 0x24]
cmp byte [eax + edx], 0
je 0x1001388e
inc eax
cmp eax, ecx
jb 0x10013881
jmp 0x100138a2
mov ecx, eax
mov eax, dword [esp + 0x1c]
inc eax
mov dword [esp + 0x10], ecx
mov dword [esp + 0x1c], eax
mov ebx, 1
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x24]
add eax, ecx
push edx
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 0x2c], ecx
push 1
push eax
lea ecx, [esp + 0x38]
call fcn.10014210
test ebx, ebx
jne 0x10013918
mov eax, dword [esp + 0x10]
mov ecx, 0x1000
cmp eax, ecx
jne 0x10013918
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
add eax, ecx
sub edx, ecx
cmp eax, edi
mov dword [esp + 0x20], eax
mov dword [esp + 0x18], edx
jl 0x100137fc
jmp 0x10013918
push 2
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ecx, dword [esp + 0x24]
push ecx
call sub.MSVCRT.dll_free
mov edx, dword [esp + 0x58]
add esp, 4
mov dword [edx], 0
mov edi, dword [esp + 0x14]
test edi, edi
jle 0x100139a6
mov eax, dword [esp + 0x54]
lea ecx, [edi + 1]
push ecx
mov dword [eax], 1
call fcn.1000fce0
mov edx, dword [esp + 0x20]
mov ebx, dword [esp + 0x54]
add esp, 4
add edi, edx
mov dword [ebx], eax
push 0
push 0
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebp, dword [esp + 0x30]
mov eax, dword [esp + 0x34]
mov ebx, dword [ebx]
cmp ebp, eax
je 0x10013992
mov ecx, dword [ebp + 4]
mov esi, dword [ebp]
mov eax, ecx
mov edi, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp]
mov edi, dword [ebp + 4]
push ecx
add ebx, edi
call sub.MSVCRT.dll_free
mov eax, dword [esp + 0x38]
add ebp, 8
add esp, 4
cmp ebp, eax
jne 0x10013960
mov edx, dword [esp + 0x50]
mov ecx, dword [esp + 0x14]
mov eax, dword [edx]
mov byte [eax + ecx], 0
mov eax, dword [esp + 0x34]
jmp 0x100139b4
mov eax, dword [esp + 0x34]
mov edx, dword [esp + 0x54]
mov dword [edx], 0
mov ecx, dword [esp + 0x30]
cmp eax, eax
mov edx, eax
pop edi
je 0x100139d3
mov esi, dword [eax]
add eax, 8
mov dword [ecx], esi
mov esi, dword [eax - 4]
mov dword [ecx + 4], esi
add ecx, 8
cmp eax, edx
jne 0x100139bf
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x50]
xor eax, eax
cmp dword [ecx], 0
mov edx, dword [esp + 0x2c]
sete al
push edx
mov esi, eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov ecx, dword [esp + 0x3c]
add esp, 4
mov eax, esi
mov dword fs:[0], ecx
pop esi
pop ebp
pop ebx
add esp, 0x38
ret