Function at 0x4579b0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c6da0
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push ebx
push esi
push edi
mov eax, dword [0x4fad60]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0xc]
xor edi, edi
mov dword [eax], edi
mov ecx, dword [0x505c44]
mov edx, dword [0x505c40]
push ecx
push edx
lea eax, [ebp - 0x2c]
push eax
push 0x505c40
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x1c], edi
call fcn.00458b40
mov ecx, dword [0x505c54]
mov edx, dword [ecx + 4]
push edx
mov ecx, 0x505c50
call fcn.00407cc0
mov eax, dword [0x505c54]
mov dword [eax + 4], eax
mov eax, dword [0x505c54]
mov dword [eax], eax
mov eax, dword [0x505c54]
mov dword [eax + 8], eax
or eax, 0xffffffff
xor ecx, ecx
mov esi, 0x505c08
mov dword [0x505c58], edi
call fcn.00404150
or eax, 0xffffffff
xor ecx, ecx
mov esi, 0x505c24
call fcn.00404150
mov eax, dword [ebp + 8]
mov dword [ebp - 4], edi
cmp dword [eax + 0x14], 8
jb 0x457a61
mov eax, dword [eax]
push edi
push 0x80
push 3
push edi
push 3
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [ebp - 0x2c], esi
cmp esi, 0xffffffff
je 0x457aa9
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 2
push edi
push edi
push esi
call ebx
cmp eax, edi
jl 0x457aa2
jne 0x457abf
mov ebx, dword [ebp + 8]
mov ecx, 0x505c08
call fcn.00456d80
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push edi
push edi
push edi
push esi
call ebx
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
lea eax, [ebp - 0x18]
push eax
push 4
lea ecx, [ebp - 0x24]
push ecx
push esi
call ebx
test eax, eax
je 0x457aa2
cmp dword [ebp - 0x18], 4
jne 0x457aa2
cmp dword [ebp - 0x24], 0x23535023
jne 0x457aa2
push edi
lea edx, [ebp - 0x18]
push edx
push 8
lea eax, [ebp - 0x34]
push eax
push esi
call ebx
test eax, eax
je 0x457aa2
cmp dword [ebp - 0x18], 8
jne 0x457aa2
push edi
lea ecx, [ebp - 0x18]
push ecx
push 2
lea edx, [ebp - 0x14]
push edx
push esi
call ebx
test eax, eax
je 0x457aa2
cmp dword [ebp - 0x18], 2
jne 0x457aa2
mov ax, word [ebp - 0x14]
cmp ax, di
jle 0x457aa2
cwde
push eax
call fcn.0048d7af
movsx edx, word [ebp - 0x14]
add esp, 4
push 0
lea ecx, [ebp - 0x18]
push ecx
mov edi, eax
push edx
push edi
push esi
mov dword [ebp - 0x20], edi
call ebx
test eax, eax
je 0x457c67
movsx eax, word [ebp - 0x14]
cmp eax, dword [ebp - 0x18]
jne 0x457c67
push 0
lea ecx, [ebp - 0x18]
push ecx
push 4
lea edx, [ebp - 0x28]
push edx
push esi
call ebx
test eax, eax
je 0x457c67
cmp dword [ebp - 0x18], 4
jne 0x457c67
cmp dword [ebp - 0x28], 1
jne 0x457c67
mov ecx, dword [ebp + 0xc]
push 0
lea eax, [ebp - 0x18]
push eax
push 4
push ecx
push esi
call ebx
test eax, eax
je 0x457c67
cmp dword [ebp - 0x18], 4
jne 0x457c67
mov edx, dword [ebp + 0xc]
mov eax, dword [edx]
test eax, eax
je 0x457c2c
push eax
call fcn.0048d7af
mov edx, dword [ebp + 0xc]
add esp, 4
push 0
lea ecx, [ebp - 0x18]
push ecx
mov ecx, dword [edx]
push ecx
push eax
push esi
mov dword [ebp - 0x1c], eax
call ebx
test eax, eax
je 0x457c0e
mov edx, dword [ebp + 0xc]
mov eax, dword [edx]
cmp dword [ebp - 0x18], eax
jne 0x457c0e
mov ebx, dword [ebp - 0x1c]
push ebx
push eax
movsx eax, word [ebp - 0x14]
push ebx
push eax
push edi
lea ecx, [ebp + 0xc]
call fcn.0045ac80
test al, al
jne 0x457c2c
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.00491285
push ebx
call fcn.00491285
add esp, 8
jmp 0x457aa9
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.00491285
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.00491285
add esp, 8
jmp 0x457aa9
push edi
call fcn.00491285
add esp, 4
push esi
mov dword [ebp - 4], 0xffffffff
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [ebp + 8]
mov ecx, 0x505c08
call fcn.00456d80
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.00491285
add esp, 4
jmp 0x457aa9