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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, ebx
and esi, 1
push edi
mov dword [ebp - 4], 0
mov dword [ebp - 8], esi
mov eax, 0x104fa58
jne 0x111a739
mov eax, 0x1002128
mov edi, dword [ebp + 8]
push edi
push eax
push 0x104fa30
call fcn.0111a4a0
mov eax, ebx
shr eax, 7
add esp, 0xc
and eax, 0xffff
xor ecx, ecx
mov edx, 0x80000000
test esi, esi
je 0x111a765
or eax, 0x20000000
mov esi, ebx
and esi, 2
jne 0x111a771
mov edx, 0x80000100
test bl, 4
je 0x111a77b
mov ecx, 1
test bl, 8
je 0x111a783
or ecx, 2
test bl, 0x10
je 0x111a78b
or ecx, 4
push 0
push eax
push 3
push 0
push ecx
push edx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
or ebx, 0xffffffff
cmp edi, ebx
jne 0x111a7b3
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
test esi, esi
jne 0x111a7fd
xor eax, eax
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
push 0x28
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x50]
push eax
push esi
push edi
mov dword [ebp - 0x50], ebx
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x34], ebx
call dword [sym.imp.KERNEL32.dll_SetFileInformationByHandle]
lea ecx, [ebp + 8]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, ebx
jne 0x111a823
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
test eax, eax
je 0x111a823
call ebx
mov esi, eax
jmp 0x111a8dd
cmp dword [ebp + 8], 0
je 0x111a833
mov esi, 0x18
jmp 0x111a8dd
mov edx, dword [ebp + 0x14]
mov eax, dword [edx]
test eax, eax
je 0x111a84a
cmp esi, eax
jbe 0x111a84a
mov esi, 0xdf
jmp 0x111a8dd
cmp dword [ebp - 8], 0
mov eax, esi
mov dword [ebp + 0xc], eax
je 0x111a889
push 3
push 0x18
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0x10]
push ecx
push edi
call dword [sym.imp.ntdll.dll_NtQueryVolumeInformationFile]
test eax, eax
jge 0x111a877
push eax
call dword [sym.imp.ntdll.dll_RtlNtStatusToDosError]
mov esi, eax
jmp 0x111a8dd
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp + 0xc]
lea eax, [ecx + edx - 1]
dec ecx
not ecx
and eax, ecx
mov dword [ebp + 0xc], eax
push 4
push 0x1000
push eax
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov ebx, eax
test ebx, ebx
jne 0x111a8a9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x111a8e0
mov ecx, dword [ebp + 0xc]
push 0
lea eax, [ebp + 0xc]
push eax
push ecx
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x111a8ce
cmp dword [ebp + 0xc], esi
jae 0x111a8ce
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x111a8e0
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp + 0x14]
mov dword [edx], ebx
mov dword [eax], esi
xor esi, esi
mov dword [ebp - 4], esi
mov ebx, dword [ebp - 4]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
je 0x111a8f9
push 0x8000
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualFree]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10