Function at 0x457650
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4cb4c8
mov eax, dword fs:[0]
push eax
sub esp, 0x34
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 edi, dword [ebp + 8]
mov eax, dword [edi + 0x3c]
mov ecx, dword [edi + 0x38]
lea esi, [edi + 0x38]
push eax
push ecx
lea eax, [ebp - 0x34]
push eax
xor ebx, ebx
push esi
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x24], ebx
call fcn.00458b40
mov ecx, dword [esi + 0x14]
mov edx, dword [ecx + 4]
push edx
lea ecx, [esi + 0x10]
call fcn.00407cc0
mov eax, dword [esi + 0x14]
mov dword [eax + 4], eax
mov eax, dword [esi + 0x14]
mov dword [eax], eax
mov eax, dword [esi + 0x14]
mov dword [eax + 8], eax
mov dword [esi + 0x18], ebx
or eax, 0xffffffff
xor ecx, ecx
mov esi, edi
call fcn.00404150
lea esi, [edi + 0x1c]
or eax, 0xffffffff
xor ecx, ecx
call fcn.00404150
mov eax, dword [ebp + 0xc]
mov dword [ebp - 4], ebx
cmp dword [eax + 0x14], 8
jb 0x4576e5
mov eax, dword [eax]
push ebx
push 0x80
push 3
push ebx
push 3
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [ebp - 0x34], esi
cmp esi, 0xffffffff
je 0x457990
push 2
push ebx
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, ebx
jl 0x457989
jne 0x457746
mov ebx, dword [ebp + 0xc]
mov ecx, edi
call fcn.00456d80
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
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 ebx
push ebx
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
lea eax, [ebp - 0x18]
push eax
push 4
lea ecx, [ebp - 0x28]
push ecx
push esi
call edi
test eax, eax
je 0x457989
cmp dword [ebp - 0x18], 4
jne 0x457989
cmp dword [ebp - 0x28], 0x23535023
jne 0x457989
push ebx
lea edx, [ebp - 0x18]
push edx
push 8
lea eax, [ebp - 0x40]
push eax
push esi
call edi
test eax, eax
je 0x457989
cmp dword [ebp - 0x18], 8
jne 0x457989
push ebx
lea ecx, [ebp - 0x18]
push ecx
push 2
lea edx, [ebp - 0x14]
push edx
push esi
call edi
test eax, eax
je 0x457989
cmp dword [ebp - 0x18], 2
jne 0x457989
mov ax, word [ebp - 0x14]
cmp ax, bx
jle 0x457989
cwde
push eax
call fcn.0048d7af
movsx edx, word [ebp - 0x14]
add esp, 4
push 0
lea ecx, [ebp - 0x18]
push ecx
mov ebx, eax
push edx
push ebx
push esi
mov dword [ebp - 0x1c], ebx
call edi
test eax, eax
je 0x457947
movsx eax, word [ebp - 0x14]
cmp eax, dword [ebp - 0x18]
jne 0x457947
push 0
lea ecx, [ebp - 0x18]
push ecx
push 4
lea edx, [ebp - 0x2c]
push edx
push esi
call edi
test eax, eax
je 0x457947
cmp dword [ebp - 0x18], 4
jne 0x457947
cmp dword [ebp - 0x2c], 1
jne 0x457947
push 0
lea eax, [ebp - 0x18]
push eax
push 4
lea ecx, [ebp - 0x20]
push ecx
push esi
call edi
test eax, eax
je 0x457947
cmp dword [ebp - 0x18], 4
jne 0x457947
mov eax, dword [ebp - 0x20]
test eax, eax
je 0x4578ff
push eax
call fcn.0048d7af
add esp, 4
push 0
mov ebx, eax
mov eax, dword [ebp - 0x20]
lea edx, [ebp - 0x18]
push edx
push eax
push ebx
push esi
mov dword [ebp - 0x24], ebx
call edi
test eax, eax
je 0x457937
mov eax, dword [ebp - 0x20]
cmp dword [ebp - 0x18], eax
jne 0x457937
mov dword [ebp - 0x30], vtable.piy::CDesEnc.0
mov edi, dword [ebp - 0x1c]
push ebx
push eax
mov byte [ebp - 4], 1
movsx ecx, word [ebp - 0x14]
push ebx
push ecx
push edi
lea ecx, [ebp - 0x30]
call fcn.0045ac80
test al, al
jne 0x4578cb
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.00491285
add esp, 4
push ebx
call fcn.00491285
add esp, 4
jmp 0x457990
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp + 8]
push edx
push ebx
push eax
call fcn.00456810
push ebx
test al, al
jne 0x4578f4
call fcn.00491285
add esp, 4
push edi
call fcn.00491285
add esp, 4
jmp 0x457990
call fcn.00491285
mov ebx, dword [ebp - 0x1c]
add esp, 4
push ebx
call fcn.00491285
add esp, 4
push esi
mov dword [ebp - 4], 0xffffffff
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
call fcn.00456d80
mov al, 1
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]
mov ecx, dword [ebp - 0x1c]
push ecx
jmp 0x4578b5
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call fcn.00491285
add esp, 4
jmp 0x457990
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
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