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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
mov eax, edx
mov word [ebp - 0xc], 0xbbef
xor edx, edx
mov dword [ebp - 0x14], eax
push edx
push 0x80
push 3
push edx
push 1
push SysReAllocString
push ecx
mov dword [ebp - 0x18], edx
mov esi, edx
mov byte [ebp - 0xa], 0xbf
mov edi, edx
mov dword [eax], edx
mov dword [ebp - 0x10], edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x43058a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x430588
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4305af
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4305af
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4305b1
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4307ed
push 2
pop edx
cmp edi, edx
jbe 0x4306ba
push 0
lea eax, [ebp - 0x10]
push eax
push edx
lea eax, [ebp - 8]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4305ed
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4305ef
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4307ed
push 2
pop edx
cmp dword [ebp - 0x10], edx
je 0x430602
mov esi, 0x80004005
test esi, esi
js 0x4307ed
mov eax, 0xfeff
cmp word [ebp - 8], ax
jne 0x43061e
xor al, al
sub edi, edx
jmp 0x4306c4
cmp edi, 3
jbe 0x43068c
lea eax, [ebp - 8]
mov ax, word [eax]
lea ecx, [ebp - 0xc]
cmp ax, word [ecx]
jne 0x43068c
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x43065d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x43065f
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4307ed
xor eax, eax
inc eax
cmp dword [ebp - 0x10], eax
je 0x430672
mov esi, 0x80004005
test esi, esi
js 0x4307ed
cmp byte [ebp - 1], 0xbf
jne 0x43068c
mov dword [ebp - 0x18], 0xfde9
sub edi, 3
jmp 0x4306c1
xor eax, eax
push eax
push eax
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x4306be
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
xor eax, eax
push 2
pop edx
test esi, esi
jle 0x4306b7
movzx esi, si
or esi, 0x80070000
inc eax
jmp 0x4306c4
xor eax, eax
jmp 0x4306b7
xor eax, eax
inc eax
push 2
pop edx
test esi, esi
js 0x4307ed
push 0x404208
test al, al
je 0x43077e
lea eax, [edi + 1]
push eax
call fcn.004989c6
mov dword [ebp - 0xc], eax
pop ecx
pop ecx
test eax, eax
jne 0x4306f5
mov esi, 0x8007000e
jmp 0x4307ed
push 0
lea ecx, [ebp - 8]
mov byte [eax + edi], 0
push ecx
push edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x430721
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x430723
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x430778
push 0x404208
xor ecx, ecx
lea eax, [edi + 2]
push 2
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004989c6
pop ecx
pop ecx
mov ecx, dword [ebp - 0x14]
mov dword [ecx], eax
lea ecx, [edi + 1]
mov edi, dword [ebp - 0xc]
push ecx
push eax
push 0xffffffffffffffff
push edi
push 0
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, dword [ebp - 0x14]
mov ecx, dword [ecx]
test eax, eax
jle 0x43076f
xor edx, edx
mov word [ecx + eax*2], dx
jmp 0x43077b
push ecx
call sub.msvcrt.dll_free
pop ecx
jmp 0x43077b
mov edi, dword [ebp - 0xc]
push edi
jmp 0x4307e7
mov eax, edi
xor ecx, ecx
shr eax, 1
inc eax
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004989c6
pop ecx
pop ecx
mov ecx, dword [ebp - 0x14]
mov dword [ecx], eax
test eax, eax
jne 0x4307a4
mov esi, 0x8007000e
test esi, esi
js 0x4307ed
push 0
lea ecx, [ebp - 0x18]
push ecx
push edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4307d0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4307d0
movzx esi, si
or esi, 0x80070000
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax]
test esi, esi
js 0x4307e6
mov eax, dword [ebp - 0x18]
shr eax, 1
xor edx, edx
mov word [ecx + eax*2], dx
jmp 0x4307ed
push ecx
call sub.msvcrt.dll_free
pop ecx
cmp ebx, 0xffffffff
je 0x4307f9
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 8