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

Disassembly:
push 0xffffffffffffffff
push 0x11f9f0d8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
mov eax, dword [esp + 0x28]
push esi
xor esi, esi
test eax, eax
mov dword [esp + 8], esi
je 0x11cad9a9
mov dword [eax], esi
push ebx
push ebp
push edi
mov edi, dword [esp + 0x28]
test edi, edi
je 0x11cadd44
push edi
call fcn.11e67d05
add esp, 4
test eax, eax
je 0x11cadd44
mov ebp, dword [esp + 0x2c]
test ebp, ebp
je 0x11cadd44
push 0
push 0
push 3
push 0
push 1
push bind
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x11cadd44
lea eax, [esp + 0x10]
mov dword [esp + 0x10], 0
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
mov eax, dword [esp + 0x10]
test eax, eax
mov eax, dword [0x12133f80]
jne 0x11cadc91
test eax, eax
je 0x11cada38
push ebp
push esi
push edi
push str.GetFileHeadOrTail_lpszFile__s__dwFileSize__d__dwByte__d_
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0x18
test esi, esi
je 0x11cadd39
mov eax, dword [esp + 0x38]
test eax, eax
je 0x11cada53
lea ecx, [ebp + ebp]
cmp ecx, esi
sbb edx, edx
inc edx
mov dword [eax], edx
cmp esi, ebp
ja 0x11cadb07
lea ecx, [esp + 0x38]
call fcn.11e923e0
xor eax, eax
lea ebp, [esi + 2]
push 0xffffffffffffffff
mov dword [esp + 0x24], eax
push ebp
lea ecx, [esp + 0x40]
mov dword [esp + 0x30], eax
call fcn.11e925f0
lea ecx, [esp + 0x38]
call fcn.11e92ce0
mov ecx, ebp
mov edi, eax
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
push 0
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x3c]
push eax
push esi
call fcn.11e92ce0
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x11cadcb3
cmp dword [esp + 0x28], esi
jne 0x11cadcb3
mov ecx, dword [esp + 0x30]
test ecx, ecx
je 0x11cadad7
lea edx, [esp + 0x38]
push edx
call fcn.11e92990
mov ecx, dword [esp + 0x34]
test ecx, ecx
je 0x11cadae9
lea eax, [esp + 0x38]
push eax
call fcn.11e92990
lea ecx, [esp + 0x38]
mov dword [esp + 0x20], 0xffffffff
call fcn.11e92540
mov dword [esp + 0x14], 1
jmp 0x11cadd39
lea ecx, [esp + 0x38]
call fcn.11e923e0
lea esi, [ebp + 2]
push 0xffffffffffffffff
mov dword [esp + 0x24], 1
push esi
lea ecx, [esp + 0x40]
mov dword [esp + 0x34], 0
call fcn.11e925f0
lea ecx, [esp + 0x38]
call fcn.11e92ce0
mov ecx, esi
mov edi, eax
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
push 0
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x30]
lea ecx, [esp + 0x3c]
push eax
push ebp
call fcn.11e92ce0
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x11cadd0b
cmp dword [esp + 0x2c], ebp
jne 0x11cadd0b
mov ecx, dword [esp + 0x30]
test ecx, ecx
je 0x11cadbb5
lea edx, [esp + 0x38]
push edx
call fcn.11e92990
mov eax, dword [0x12133f80]
test eax, eax
je 0x11cadbb5
lea ecx, [esp + 0x38]
call fcn.11e925e0
push eax
push 0x181
push str.test_test___d___d_
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0x14
lea ecx, [esp + 0x28]
call fcn.11e923e0
push 0xffffffffffffffff
push esi
lea ecx, [esp + 0x30]
mov byte [esp + 0x28], 2
call fcn.11e925f0
lea ecx, [esp + 0x28]
call fcn.11e92ce0
mov ecx, esi
mov edi, eax
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
push 2
and ecx, 3
push 0
rep stosb byte es:[edi], al
mov eax, ebp
neg eax
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea ecx, [esp + 0x2c]
push 0
push ecx
push ebp
lea ecx, [esp + 0x34]
call fcn.11e92ce0
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x11cadcde
cmp dword [esp + 0x2c], ebp
jne 0x11cadcde
mov ecx, dword [esp + 0x34]
test ecx, ecx
je 0x11cadc65
lea edx, [esp + 0x28]
push edx
call fcn.11e92990
mov eax, dword [0x12133f80]
test eax, eax
je 0x11cadc65
lea ecx, [esp + 0x28]
call fcn.11e925e0
push eax
push 0x191
push str.test_test___d___d_
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0x14
lea ecx, [esp + 0x28]
mov byte [esp + 0x20], 1
call fcn.11e92540
lea ecx, [esp + 0x38]
mov dword [esp + 0x20], 0xffffffff
call fcn.11e92540
mov dword [esp + 0x14], 1
jmp 0x11cadd39
test eax, eax
je 0x11cadd39
push edi
push str.GetFileHeadOrTail_lpszFile__s__too_big
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0x10
jmp 0x11cadd39
mov eax, dword [0x12133f80]
test eax, eax
je 0x11cadcd0
push str.GetFileHeadOrTail_read_file_fail_____1
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0xc
mov dword [esp + 0x20], 0xffffffff
lea ecx, [esp + 0x38]
jmp 0x11cadd34
mov eax, dword [0x12133f80]
test eax, eax
je 0x11cadcfb
push str.GetFileHeadOrTail_read_file_fail_____3
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0xc
lea ecx, [esp + 0x28]
mov byte [esp + 0x20], 1
call fcn.11e92540
jmp 0x11cadd28
mov eax, dword [0x12133f80]
test eax, eax
je 0x11cadd28
push str.GetFileHeadOrTail_read_file_fail_____2
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0xc
mov dword [esp + 0x20], 0xffffffff
lea ecx, [esp + 0x38]
call fcn.11e92540
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [esp + 0x14]
mov eax, dword [0x12133f80]
pop edi
pop ebp
pop ebx
test eax, eax
je 0x11cadd65
push esi
push str.GetFileHeadOrTail_ret___d_
push str.CFileTypeMgr
push 0xffffffffffffffff
call fcn.11ca5810
add esp, 0x10
mov ecx, dword [esp + 0xc]
mov eax, esi
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret 0x14