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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100a95f8
mov eax, dword fs:[0]
push eax
sub esp, 0x44
mov eax, dword [0x100db55c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
push 0
push 0x80
push 3
push 0
push 1
push 0x81
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x10016853
lea eax, [ebp - 0x50]
xorps xmm0, xmm0
push eax
push esi
movlpd qword [ebp - 0x50], xmm0
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x100166c7
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x10016853
cmp dword [ebp - 0x4c], 0
jg 0x100166bb
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x44], eax
test eax, eax
je 0x100166bb
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
push 0
push eax
lea ecx, [ebp - 0x28]
mov dword [ebp - 4], 0
call fcn.10018240
cmp dword [ebp - 0x14], 0x10
lea ecx, [ebp - 0x48]
push 0
push ecx
push dword [ebp - 0x44]
lea eax, [ebp - 0x28]
mov dword [ebp - 0x48], 0
cmovae eax, dword [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10016844
mov eax, dword [ebp - 0x44]
cmp eax, dword [ebp - 0x48]
jne 0x10016844
cmp eax, 3
jbe 0x100167f0
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x28]
mov esi, dword [ebp - 0x28]
cmp edx, 0x10
cmovae eax, esi
cmp byte [eax], 0xef
jne 0x100167f0
cmp edx, 0x10
lea eax, [ebp - 0x28]
cmovae eax, esi
cmp byte [eax + 1], 0xbb
jne 0x100167f0
cmp edx, 0x10
lea eax, [ebp - 0x28]
cmovae eax, esi
cmp byte [eax + 2], 0xbf
jne 0x100167f0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0xf
mov byte [ebp - 0x40], 0
cmp eax, 3
jb 0x10016870
add eax, 0xfffffffd
or ecx, 0xffffffff
cmp eax, 0xffffffff
cmovb ecx, eax
cmp edx, 0x10
lea eax, [ebp - 0x28]
cmovae eax, esi
push ecx
add eax, 3
lea ecx, [ebp - 0x40]
push eax
call fcn.100183a0
lea eax, [ebp - 0x40]
cmp edi, eax
je 0x100167e6
mov ecx, edi
call fcn.100057d0
movups xmm0, xmmword [ebp - 0x40]
mov byte [ebp - 0x40], 0
movups xmmword [edi], xmm0
movq xmm0, qword [ebp - 0x30]
movq qword [edi + 0x10], xmm0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0xf
lea ecx, [ebp - 0x40]
call fcn.100057d0
jmp 0x1001684b
movups xmm0, xmmword [edi]
movups xmm1, xmmword [ebp - 0x28]
movq xmm2, qword [ebp - 0x18]
movups xmmword [ebp - 0x28], xmm0
movq xmm0, qword [edi + 0x10]
movq qword [ebp - 0x18], xmm0
mov edx, dword [ebp - 0x14]
movups xmmword [edi], xmm1
movq qword [edi + 0x10], xmm2
cmp edx, 0x10
jb 0x10016853
mov ecx, dword [ebp - 0x28]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x10016838
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x10016875
push edx
push ecx
call fcn.1006a79e
add esp, 8
jmp 0x10016853
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x28]
call fcn.100057d0
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1006a7ac
mov esp, ebp
pop ebp
ret
call fcn.10011060
call fcn.10079a6e
int3