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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x546073
mov eax, dword fs:[0]
push eax
sub esp, 0x2c8
mov eax, dword [0x594584]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [edi]
mov esi, dword [ebp + 8]
test eax, eax
je 0x460562
push eax
call fcn.00512911
add esp, 4
mov eax, dword [edi + 4]
test eax, eax
je 0x460572
push eax
call fcn.00512911
add esp, 4
mov dword [edi], 0
mov dword [edi + 4], 0
mov dword [edi + 8], 0
call fcn.00452f20
push eax
lea ecx, [ebp - 0xac]
call fcn.0044efb0
mov dword [ebp - 4], 0
call fcn.00452f40
mov ecx, eax
call fcn.0044ff70
test al, al
je 0x46069d
push esi
lea ecx, [ebp - 0xac]
call fcn.0044f560
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocStringLen
lea ecx, [ebp - 0xac]
call fcn.0040d220
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x2d0], eax
cmp eax, 0xffffffff
jne 0x4605f9
push 0x63
push str.Error_opening_file
jmp 0x4607ef
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x4607a4
cmp ebx, 0x400000
ja 0x4607b4
lea esi, [ebx + 8]
mov dword [ebp - 0x2cc], 0
push 0x59b6d0
push esi
call fcn.004cc2b2
push esi
mov esi, eax
mov dword [ebp - 0x2d4], eax
push 0
push esi
call fcn.0050f150
add esp, 0x14
lea eax, [ebp - 0x2cc]
push 0
push eax
push ebx
push esi
push dword [ebp - 0x2d0]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x2d0]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x2cc], ebx
je 0x46068b
push esi
call fcn.004cc2ad
add esp, 4
mov ecx, edi
call fcn.00460130
push 0x63
push str.Could_not_read_file
jmp 0x4607ef
push dword [ebp + 0xc]
mov ecx, edi
push ebx
push esi
call fcn.00460890
push esi
jmp 0x460855
call fcn.00452f40
push eax
lea ecx, [ebp - 0xac]
call fcn.0044f540
mov dword [ebp - 0x2d0], 0
mov dword [ebp - 0x2cc], 0
call fcn.00453110
test al, al
je 0x460812
call fcn.00452f50
mov ebx, eax
test ebx, ebx
jne 0x4606e6
push 0x63
push str.Error_opening_zip_file
jmp 0x4607ef
mov ecx, esi
mov dword [ebp - 0x18], 0
xor eax, eax
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x460700
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x28]
call fcn.0040f730
lea eax, [ebp - 0x2c4]
mov byte [ebp - 4], 1
push eax
lea eax, [ebp - 0x2d4]
push eax
lea eax, [ebp - 0x28]
push eax
push ebx
call fcn.00482350
mov edx, dword [ebp - 0x14]
add esp, 0x10
test eax, eax
mov byte [ebp - 4], 0
sete al
mov byte [ebp - 0x2c5], al
cmp edx, 8
jb 0x460787
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x460777
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x46088a
push edx
push ecx
call fcn.004cbf26
mov al, byte [ebp - 0x2c5]
add esp, 8
test al, al
je 0x460794
push 0x63
push str.Could_not_find_ziped_file
jmp 0x4607ef
mov eax, dword [ebp - 0xb0]
mov dword [ebp - 0x2cc], eax
test eax, eax
jne 0x4607ad
push 0x63
push str.File_is_empty
jmp 0x4607ef
cmp eax, 0x400000
jbe 0x4607bd
push 0x63
push str.File_too_large
jmp 0x4607ef
push 0x59b6d0
push eax
call fcn.004cc2b2
push dword [ebp - 0x2cc]
mov dword [ebp - 0x2d0], eax
push eax
push dword [ebp - 0x2d4]
push ebx
call fcn.00482180
add esp, 0x18
test eax, eax
jne 0x460839
push 0x63
push str.Could_not_unzip_file
lea eax, [edi + 0x10]
push eax
call fcn.00526355
push 0x31
lea eax, [edi + 0xd8]
push 0x54e970
push eax
call fcn.00526355
add esp, 0x18
xor bl, bl
jmp 0x46085f
lea eax, [ebp - 0x2cc]
push eax
lea eax, [ebp - 0x2d0]
push eax
push esi
lea ecx, [ebp - 0xac]
call fcn.0040d220
push eax
call fcn.00484cc0
add esp, 0x10
test eax, eax
js 0x4607e8
push dword [ebp + 0xc]
mov ecx, edi
push dword [ebp - 0x2cc]
push dword [ebp - 0x2d0]
call fcn.00460890
push dword [ebp - 0x2d0]
mov bl, al
call fcn.004cc2ad
add esp, 4
lea ecx, [ebp - 0xac]
call fcn.00407840
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004cc1ce
mov esp, ebp
pop ebp
ret 8
call fcn.005127d9
int3