Function at 0x10002ef6
Capabilities:
Check if file exists
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x5b44]
mov eax, 0x5b44
call fcn.100229d0
push 0xffffffffffffffff
push 0x10037129
mov eax, dword fs:[0]
push eax
sub esp, 0x58
mov eax, dword [0x1004ac9c]
xor eax, ebp
mov dword [ebp + 0x5b40], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0x5b4c]
mov esi, ecx
xor ebx, ebx
lea ecx, [ebp - 0x5c]
mov dword [ebp - 0x24], eax
mov dword [ebp - 4], ebx
call fcn.1001385f
push ebx
push 0xffffffffffffffff
push ebx
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 1
call fcn.1000fcbf
mov byte [ebp - 4], 2
push esi
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x40], ebx
call fcn.10010554
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x14]
cmp dword [eax - 0xc], ebx
jne 0x10002fca
lea ecx, [eax - 0x10]
call fcn.1000c74e
mov ecx, dword [ebp - 0x2c]
add ecx, 0xfffffff0
mov dword [ebp - 0x3c], vtable.CFileException.0
call fcn.1000c74e
lea ecx, [ebp - 0x5c]
mov byte [ebp - 4], bl
call fcn.10013933
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x5b40]
xor ecx, ebp
call fcn.1001f81d
add ebp, 0x5b44
leave
ret
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x10002fdd
mov ecx, dword [ebp - 0x14]
add ecx, 0xfffffff0
jmp 0x10002f83
mov eax, dword [ebp - 0x14]
mov esi, dword [eax - 0xc]
push 0x5c
push eax
call fcn.1001e72f
cmp eax, ebx
pop ecx
pop ecx
jne 0x10002ff6
or eax, 0xffffffff
jmp 0x10002ffb
sub eax, dword [ebp - 0x14]
sar eax, 1
push esi
inc eax
push eax
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x14]
call fcn.1000ffbe
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
mov byte [ebp - 4], 4
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
push ebx
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x4c]
push eax
push ecx
mov ecx, esp
mov dword [ebp - 0x64], esp
push 0x1003f730
call fcn.10010554
push ecx
mov byte [ebp - 4], 5
lea eax, [ebp - 0x14]
mov dword [ebp - 0x44], esp
mov ecx, esp
push eax
call fcn.10010598
lea ecx, [ebp - 0x1d]
mov byte [ebp - 4], 4
call fcn.10010920
mov edi, eax
cmp edi, 0x1400000
jle 0x1000307c
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff0
call fcn.1000c74e
jmp 0x10002fd5
push edi
call fcn.10010c6c
pop ecx
push ebx
mov esi, eax
lea eax, [ebp - 0x40]
push eax
push edi
push esi
push dword [ebp - 0x28]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.ole32.dll_CoInitialize]
lea eax, [ebp]
call fcn.10003875
push dword [ebp - 0x24]
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 6
call fcn.10010554
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 7
call fcn.10003463
push dword [ebp - 0x18]
mov dword [ebp - 0x24], eax
call fcn.1000fc24
pop ecx
push eax
lea ecx, [ebp - 0x18]
call fcn.1000c727
lea eax, [ebp - 0x44]
push eax
push dword [ebp - 0x24]
lea eax, [ebp]
push esi
push edi
push eax
mov dword [ebp + 0x248c], 0xea60
call fcn.10004ded
cmp esi, ebx
mov edi, eax
je 0x100030fd
push esi
call fcn.10010c67
pop ecx
push dword [ebp - 0x28]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea esi, [ebp + 0x5a18]
call fcn.1000f8fb
mov eax, dword [ebp + 0x5a18]
mov ecx, esi
call dword [eax + 0x68]
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff0
call fcn.1000c74e
lea eax, [ebp]
push eax
mov byte [ebp - 4], 4
call fcn.100038ad
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff0
call fcn.1000c74e
mov ecx, dword [ebp - 0x14]
add ecx, 0xfffffff0
call fcn.1000c74e
mov ecx, dword [ebp - 0x2c]
add ecx, 0xfffffff0
mov dword [ebp - 0x3c], vtable.CFileException.0
call fcn.1000c74e
lea ecx, [ebp - 0x5c]
mov byte [ebp - 4], bl
call fcn.10013933
cmp edi, ebx
jne 0x10002fa5
mov al, 1
jmp 0x10002fa7