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

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1003c
call fcn.1002fb29
mov eax, dword [0x100400b0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, ecx
mov esi, edx
test edi, edi
je 0x100108b1
xor eax, eax
cmp ax, word [edi]
je 0x100108b1
test esi, esi
je 0x100108b1
cmp ax, word [esi]
je 0x100108b1
push esi
push edi
call fcn.100108c2
pop ecx
pop ecx
test eax, eax
jne 0x1001065f
xor eax, eax
inc eax
jmp 0x100108b3
mov ebx, dword [sym.imp.kernel32.dll_CreateFileW]
xor eax, eax
push eax
push eax
push 3
push eax
push 1
push 1
push edi
call ebx
mov edi, eax
cmp edi, 0xffffffff
je 0x100108b1
xor eax, eax
push eax
push eax
push 3
push eax
push 1
push 1
push esi
call ebx
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x1001069f
push edi
call dword [sym.imp.kernel32.dll_CloseHandle]
jmp 0x100108b1
and dword [ebp - 0x10010], 0
lea eax, [ebp - 0x10010]
mov esi, dword [sym.imp.kernel32.dll_GetFileSize]
push eax
push edi
call esi
and dword [ebp - 0x10014], 0
mov dword [ebp - 0x1000c], eax
lea eax, [ebp - 0x10014]
push eax
push ebx
call esi
mov edx, eax
mov eax, dword [ebp - 0x10010]
cmp eax, dword [ebp - 0x10014]
jne 0x100108a5
mov ecx, dword [ebp - 0x1000c]
cmp ecx, edx
jne 0x100108a5
xor esi, esi
xorps xmm0, xmm0
add esi, ecx
movlpd qword [ebp - 0x10028], xmm0
push 0
pop edx
adc eax, edx
mov ecx, esi
shrd ecx, eax, 0xf
and esi, 0x7fff
shr eax, 0xf
mov dword [ebp - 0x1003c], ecx
mov dword [ebp - 0x10038], eax
mov dword [ebp - 0x10034], esi
cmp eax, edx
jb 0x10010826
ja 0x10010736
cmp ecx, edx
jbe 0x10010826
mov eax, dword [ebp - 0x10024]
mov dword [ebp - 0x1000c], eax
mov eax, dword [ebp - 0x10028]
mov dword [ebp - 0x10024], eax
push edx
lea eax, [ebp - 0x10018]
mov dword [ebp - 0x10018], edx
push eax
push 0x8000
lea eax, [ebp - 0x8008]
mov dword [ebp - 0x1001c], edx
push eax
push edi
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
je 0x100108a5
push 0
lea eax, [ebp - 0x1001c]
push eax
push 0x8000
lea eax, [ebp - 0x10008]
push eax
push ebx
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
je 0x100108a5
mov eax, 0x8000
cmp dword [ebp - 0x10018], eax
jne 0x100108a5
cmp dword [ebp - 0x1001c], eax
jne 0x100108a5
xor edx, edx
lea eax, [ebp - 0x8008]
mov ecx, edx
mov eax, dword [eax + ecx*4]
lea esi, [ebp - 0x10008]
cmp eax, dword [esi + ecx*4]
mov esi, dword [ebp - 0x10034]
jne 0x100108a5
inc ecx
lea eax, [ebp - 0x8008]
cmp ecx, 0x2000
jne 0x100107c8
mov eax, dword [ebp - 0x10024]
mov ecx, dword [ebp - 0x1000c]
add eax, 1
mov dword [ebp - 0x10024], eax
adc ecx, edx
mov dword [ebp - 0x1000c], ecx
cmp ecx, dword [ebp - 0x10038]
jb 0x1001074e
ja 0x10010826
cmp eax, dword [ebp - 0x1003c]
jb 0x1001074e
push edx
lea eax, [ebp - 0x1002c]
mov dword [ebp - 0x1002c], edx
push eax
push esi
lea eax, [ebp - 0x8008]
mov dword [ebp - 0x10030], edx
push eax
push edi
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
je 0x100108a5
push 0
lea eax, [ebp - 0x10030]
push eax
push esi
lea eax, [ebp - 0x10008]
push eax
push ebx
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
je 0x100108a5
cmp dword [ebp - 0x1002c], esi
jne 0x100108a5
cmp dword [ebp - 0x10030], esi
jne 0x100108a5
push esi
lea eax, [ebp - 0x10008]
push eax
lea eax, [ebp - 0x8008]
push eax
call fcn.100108c2
add esp, 0xc
test eax, eax
jne 0x100108a5
mov esi, dword [sym.imp.kernel32.dll_CloseHandle]
push edi
call esi
push ebx
call esi
jmp 0x10010657
mov esi, dword [sym.imp.kernel32.dll_CloseHandle]
push edi
call esi
push ebx
call esi
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1001c65c
leave
ret