Function at 0x4feeb0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x698
mov eax, dword [0x64e2c0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x698], eax
push edi
mov edi, dword [ebp + 0x14]
mov dword [ebp - 0x648], edi
test esi, esi
jne 0x4feef3
pop edi
mov eax, 0x80070057
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push edi
call fcn.004fbad0
add esp, 4
push 0
push 0x8000000
push 3
push 0
push 1
push Ordinal_1
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
xor eax, eax
cmp esi, 0xffffffff
cmove esi, eax
mov dword [ebp - 0x64c], esi
test esi, esi
jne 0x4fef4f
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x4ffa81
movzx eax, ax
pop edi
or eax, 0x80070000
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push 0x18
lea eax, [ebp - 0x450]
push eax
push 1
push esi
call dword [sym.imp.KERNEL32.dll_GetFileInformationByHandleEx]
test eax, eax
jne 0x4fef93
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test edi, edi
jle 0x4fef7a
movzx edi, di
or edi, 0x80070000
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x444], 0
jle 0x4fefb8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, 0x800700df
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x448]
mov dword [ebp - 0x66c], eax
cmp eax, 0x12
jae 0x4fefe5
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, 0x80004005
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push 0
lea eax, [ebp - 0x41c]
mov word [ebp - 8], 0
push eax
push 0x12
lea eax, [ebp - 0x18]
mov dword [ebp - 0x41c], 0
push eax
xorps xmm0, xmm0
push esi
movups xmmword [ebp - 0x18], xmm0
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4fef65
xorps xmm0, xmm0
xor edx, edx
cmp dword [ebp - 0x41c], 0x12
push ebx
movups xmmword [ebp - 0x690], xmm0
movups xmmword [ebp - 0x680], xmm0
jb case.0x4ff081.4
mov bl, byte [ebp - 7]
test bl, 0xc0
jne case.0x4ff081.0
mov ax, word [ebp - 0xc]
mov word [ebp - 0x642], ax
test ax, ax
je case.0x4ff081.4
mov ax, word [ebp - 0xa]
mov word [ebp - 0x662], ax
test ax, ax
je case.0x4ff081.4
mov cl, byte [ebp - 0x16]
movzx eax, cl
cmp eax, 0xb
ja case.0x4ff081.4
movzx eax, byte [eax + 0x4ffaa8]
jmp dword [eax*4 + 0x4ffa94]
mov edi, 0x80070032
jmp 0x4ffa77
cmp byte [ebp - 0x17], 1
jne case.0x4ff081.0
cmp word [ebp - 0x13], dx
je case.0x4ff081.0
cmp byte [ebp - 8], 8
jne case.0x4ff081.0
cmp byte [ebp - 0x11], 0x18
jne case.0x4ff081.0
test byte [ebp + 0xc], 1
je 0x4ff0c9
mov ecx, 0x58
mov dword [ebp - 0x654], ecx
mov dword [ebp - 0x674], ecx
lea edx, [ecx - 0x48]
jmp 0x4ff1ca
mov eax, 0x1c
mov edx, 0x10
mov dword [ebp - 0x654], eax
mov dword [ebp - 0x674], eax
mov eax, dword [ebp - 0x678]
and eax, 0xfffffffb
or eax, 3
mov dword [ebp - 0x678], eax
jmp 0x4ff1ca
cmp byte [ebp - 0x17], dl
jne case.0x4ff081.0
cmp word [ebp - 0x13], dx
jne case.0x4ff081.0
mov al, byte [ebp - 8]
cmp al, 0x10
je 0x4ff176
cmp al, 0x18
je 0x4ff130
cmp al, 0x20
jne case.0x4ff081.0
test byte [ebp + 0xc], 1
mov eax, 0x1c
mov dword [ebp - 0x650], 0x57
cmovne eax, dword [ebp - 0x650]
jmp 0x4ff17b
test byte [ebp + 0xc], 1
je 0x4ff14c
mov eax, 0x58
mov dword [ebp - 0x654], eax
mov dword [ebp - 0x674], eax
lea edx, [eax - 0x57]
jmp 0x4ff187
mov eax, 0x1c
mov edx, 1
mov dword [ebp - 0x654], eax
mov dword [ebp - 0x674], eax
mov eax, dword [ebp - 0x678]
and eax, 0xfffffffb
or eax, 3
mov dword [ebp - 0x678], eax
jmp 0x4ff187
mov eax, 0x56
mov dword [ebp - 0x674], eax
mov dword [ebp - 0x654], eax
cmp cl, 0xa
jne 0x4ff1ca
or edx, 8
jmp 0x4ff1ca
cmp byte [ebp - 0x17], dl
jne case.0x4ff081.0
cmp word [ebp - 0x13], dx
jne case.0x4ff081.0
cmp byte [ebp - 8], 8
jne case.0x4ff081.0
mov eax, 0x3d
cmp cl, 0xb
mov dword [ebp - 0x654], eax
mov dword [ebp - 0x674], eax
mov eax, 8
cmove edx, eax
movzx eax, word [ebp - 0x642]
mov ecx, edx
or ecx, 2
mov dword [ebp - 0x690], eax
movzx eax, word [ebp - 0x662]
test bl, 0x10
mov dword [ebp - 0x68c], eax
cmove ecx, edx
mov dword [ebp - 0x680], 1
mov eax, ecx
mov dword [ebp - 0x684], 1
or eax, 4
mov dword [ebp - 0x688], 1
test byte [ebp - 7], 0x20
cmove eax, ecx
mov cl, byte [ebp - 0x18]
mov dword [ebp - 0x658], eax
mov eax, 0x12
test cl, cl
je 0x4ff231
movzx eax, cl
add eax, 0x12
mov ebx, dword [ebp - 0x66c]
sub ebx, eax
je case.0x4ff372.88
cmp eax, 0x12
jbe 0x4ff25a
push 0
push 0
push 0
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x4ff30a
movzx eax, word [ebp - 0x662]
push 0
push 1
push 1
push eax
movzx eax, word [ebp - 0x642]
push eax
push dword [ebp - 0x654]
push edi
call fcn.004fb630
add esp, 0x1c
mov dword [ebp - 0x650], eax
test eax, eax
jns 0x4ff2a7
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x650]
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x658], 4
mov byte [ebp - 0x644], 0
jne 0x4ff691
mov eax, dword [edi + 4]
cmp ebx, eax
jae 0x4ff2e8
push edi
call fcn.004fbad0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, 0x80070026
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push 0
lea ecx, [ebp - 0x41c]
push ecx
push eax
push dword [edi + 0x30]
mov eax, dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
call eax
test eax, eax
jne 0x4ff328
push edi
call fcn.004fbad0
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test edi, edi
jle 0x4ffa77
movzx edi, di
or edi, 0x80070000
jmp 0x4ffa77
mov eax, dword [ebp - 0x41c]
cmp eax, dword [edi + 4]
je 0x4ff359
push edi
call fcn.004fbad0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, 0x80004005
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x654]
add eax, 0xffffffe4
cmp eax, 0x3c
ja case.0x4ff372.29
movzx eax, byte [eax + 0x4ffac8]
jmp dword [eax*4 + 0x4ffab4]
push 0
push 0
push 0
push edi
call fcn.004fb5a0
add esp, 0x10
mov dword [ebp - 0x650], eax
test eax, eax
je 0x4ff66b
mov ebx, dword [eax + 0x14]
mov ecx, ebx
mov dword [ebp - 0x668], ebx
mov dword [ebp - 0x694], ecx
test ecx, ecx
je 0x4ff66b
mov edi, dword [ebp - 0x650]
xor ecx, ecx
mov eax, dword [eax + 0xc]
mov edx, 0xff
mov dword [ebp - 0x660], eax
mov esi, dword [edi + 4]
cmp esi, ecx
mov dword [ebp - 0x65c], esi
mov esi, dword [ebp - 0x64c]
jbe 0x4ff440
mov edi, dword [edi]
mov esi, dword [ebp - 0x65c]
mov dword [ebp - 0x658], edi
mov dword [ebp - 0x664], esi
nop dword [eax]
test edi, edi
je 0x4ff427
mov esi, dword [ebp - 0x658]
lea edi, [ebx + 3]
nop dword [eax]
movzx eax, byte [edi]
lea edi, [edi + 4]
cmp eax, edx
cmovb edx, eax
cmp ecx, eax
cmovb ecx, eax
sub esi, 1
jne 0x4ff400
mov eax, dword [ebp - 0x660]
mov esi, dword [ebp - 0x664]
mov edi, dword [ebp - 0x658]
add ebx, eax
sub esi, 1
mov dword [ebp - 0x664], esi
jne 0x4ff3f0
mov esi, dword [ebp - 0x64c]
mov ebx, dword [ebp - 0x668]
xor edi, edi
mov dword [ebp - 0x658], edi
test ecx, ecx
jne 0x4ff465
test byte [ebp + 0xc], 2
jne 0x4ff465
mov byte [ebp - 0x644], 1
mov dword [ebp - 0x658], 1
jmp 0x4ff482
mov ecx, dword [ebp - 0x644]
cmp edx, 0xff
movzx ecx, cl
mov edi, 1
cmove ecx, edi
mov dword [ebp - 0x644], ecx
xor edi, edi
cmp dword [ebp - 0x65c], edi
jbe case.0x4ff372.29
mov esi, dword [ebp - 0x658]
push esi
push dword [ebp - 0x654]
push eax
push ebx
push eax
push ebx
call fcn.0050cc40
mov ecx, dword [ebp - 0x650]
inc edi
mov eax, dword [ebp - 0x660]
add esp, 0x18
add ebx, eax
cmp edi, dword [ecx + 4]
jb 0x4ff496
mov esi, dword [ebp - 0x64c]
jmp case.0x4ff372.29
push 0
push 0
push 0
push edi
call fcn.004fb5a0
mov ebx, eax
add esp, 0x10
mov dword [ebp - 0x65c], ebx
test ebx, ebx
je 0x4ff66b
mov eax, dword [ebx + 0x14]
xor ecx, ecx
mov dword [ebp - 0x650], eax
mov edx, 0xff
test eax, eax
je 0x4ff66b
mov ebx, dword [ebx + 4]
mov dword [ebp - 0x660], ebx
test ebx, ebx
je 0x4ff61f
mov esi, dword [ebp - 0x65c]
cmp dword [esi], 0
jbe 0x4ff541
mov ebx, dword [esi]
lea edi, [eax + 3]
movzx eax, byte [edi]
lea edi, [edi + 4]
cmp eax, edx
cmovb edx, eax
cmp ecx, eax
cmovb ecx, eax
sub ebx, 1
jne 0x4ff520
mov eax, dword [ebp - 0x650]
mov ebx, dword [ebp - 0x660]
add eax, dword [esi + 0xc]
sub ebx, 1
mov dword [ebp - 0x650], eax
mov dword [ebp - 0x660], ebx
jne 0x4ff516
jmp 0x4ff60b
cmp edx, 0xff
jne case.0x4ff372.29
mov byte [ebp - 0x644], 1
jmp case.0x4ff372.29
push 0
push 0
push 0
push edi
call fcn.004fb5a0
mov ebx, eax
add esp, 0x10
mov dword [ebp - 0x65c], ebx
test ebx, ebx
je 0x4ff66b
mov eax, dword [ebx + 0x14]
xor ecx, ecx
mov dword [ebp - 0x650], eax
mov edx, 0xff
test eax, eax
je 0x4ff66b
mov ebx, dword [ebx + 4]
mov dword [ebp - 0x660], ebx
test ebx, ebx
je 0x4ff61f
mov esi, dword [ebp - 0x65c]
nop dword [eax]
cmp dword [esi], 0
mov edi, eax
jbe 0x4ff5f7
mov ebx, dword [esi]
nop dword [eax]
movsx eax, word [edi]
lea edi, [edi + 2]
sar eax, 0x1f
movzx eax, al
cmp eax, edx
cmovb edx, eax
cmp ecx, eax
cmovb ecx, eax
sub ebx, 1
jne 0x4ff5d0
mov eax, dword [ebp - 0x650]
mov ebx, dword [ebp - 0x660]
add eax, dword [esi + 0xc]
sub ebx, 1
mov dword [ebp - 0x650], eax
mov dword [ebp - 0x660], ebx
jne 0x4ff5c0
mov esi, dword [ebp - 0x64c]
test ecx, ecx
jne 0x4ff55a
mov edi, dword [ebp - 0x648]
test byte [ebp + 0xc], 2
jne 0x4ff55a
push dword [ebp - 0x65c]
mov byte [ebp - 0x644], 1
call fcn.004ffc10
mov ebx, eax
add esp, 4
test ebx, ebx
jns case.0x4ff372.29
push edi
call fcn.004fbad0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push edi
call fcn.004fbad0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, 0x80004003
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push 0x626080
push ebx
call fcn.005b3706
mov edi, eax
add esp, 8
test edi, edi
jne 0x4ff6d0
push dword [ebp - 0x648]
call fcn.004fbad0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, 0x8007000e
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push 0
lea eax, [ebp - 0x41c]
push eax
mov eax, dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
push edi
push esi
call eax
test eax, eax
jne 0x4ff72d
push dword [ebp - 0x648]
call fcn.004fbad0
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
test ebx, ebx
jle 0x4ff70a
movzx ebx, bx
or ebx, 0x80070000
push edi
call fcn.005b301d
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x41c], ebx
je 0x4ff766
push dword [ebp - 0x648]
call fcn.004fbad0
push edi
call fcn.005b301d
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, 0x80004005
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push 0x400
lea eax, [ebp - 0x418]
mov dword [ebp - 0x64c], 0
push 0
push eax
call fcn.005b4c50
mov eax, dword [ebp - 0x658]
add esp, 0xc
test al, 0x10
je 0x4ff7f1
lea eax, [ebp - 0x64c]
push eax
lea eax, [ebp - 0x418]
push eax
push dword [ebp + 0xc]
lea eax, [ebp - 0x18]
push ebx
push edi
push eax
call fcn.004ffb10
add esp, 0x18
mov dword [ebp - 0x668], eax
test eax, eax
jns 0x4ff7eb
push dword [ebp - 0x648]
call fcn.004fbad0
push edi
call fcn.005b301d
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x668]
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x658]
test al, 8
je 0x4ff824
push eax
push 0
push 0
push 0
push dword [ebp - 0x648]
call fcn.004fb5a0
add esp, 0x10
push eax
push dword [ebp + 0xc]
mov eax, dword [ebp - 0x64c]
sub ebx, eax
add eax, edi
push ebx
push eax
call fcn.004ffc60
add esp, 0x14
jmp 0x4ff858
lea ecx, [ebp - 0x418]
push ecx
push eax
push 0
push 0
push 0
push dword [ebp - 0x648]
call fcn.004fb5a0
add esp, 0x10
push eax
push dword [ebp + 0xc]
mov eax, dword [ebp - 0x64c]
sub ebx, eax
add eax, edi
push ebx
push eax
call fcn.004fe5b0
add esp, 0x18
mov ebx, eax
test ebx, ebx
jns 0x4ff88c
push dword [ebp - 0x648]
call fcn.004fbad0
push edi
call fcn.005b301d
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
push edi
call fcn.005b301d
add esp, 4
cmp ebx, 1
sete al
mov byte [ebp - 0x644], al
push 0x1ef
xor ebx, ebx
lea eax, [ebp - 0x640]
push ebx
push eax
call fcn.005b4c50
add esp, 0xc
mov word [ebp - 0x420], bx
xorps xmm0, xmm0
movups xmmword [ebp - 0x438], xmm0
push 2
push ebx
push 0xffffffffffffffe6
push esi
movq qword [ebp - 0x428], xmm0
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x4ff93d
push ebx
lea eax, [ebp - 0x41c]
push eax
push 0x1a
lea eax, [ebp - 0x438]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4ff909
push dword [ebp - 0x648]
jmp 0x4ff302
cmp dword [ebp - 0x41c], 0x1a
je 0x4ff93d
push dword [ebp - 0x648]
call fcn.004fbad0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
mov eax, 0x80004005
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x430]
mov edx, str.TRUEVISION_XFILE.
mov edi, 0xe
nop dword [eax]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x4ff9c8
add ecx, 4
add edx, 4
sub edi, 4
jae 0x4ff950
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x4ff9c8
mov ecx, dword [ebp - 0x438]
test ecx, ecx
je 0x4ff9c8
lea eax, [ecx + 0x1ef]
cmp eax, dword [ebp - 0x66c]
ja 0x4ff9c8
push 0
push 0
push 0
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x4ff9c8
push 0
lea eax, [ebp - 0x41c]
push eax
push 0x1ef
lea eax, [ebp - 0x640]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4ff9c8
cmp dword [ebp - 0x41c], 0x1ef
lea eax, [ebp - 0x640]
cmovne eax, ebx
mov ebx, eax
mov eax, dword [ebp + 0xc]
test al, 0x10
jne 0x4ff9eb
push dword [ebp - 0x648]
push eax
push dword [ebp - 0x654]
push ebx
call fcn.004fee10
add esp, 0x10
mov dword [ebp - 0x674], eax
mov edx, dword [ebp - 0x698]
test edx, edx
je 0x4ffa58
cmp byte [ebp - 0x644], 0
movups xmm0, xmmword [ebp - 0x690]
movups xmmword [edx], xmm0
movups xmm0, xmmword [ebp - 0x680]
movups xmmword [edx + 0x10], xmm0
mov dword [edx + 0x20], 3
je 0x4ffa40
mov eax, dword [edx + 0x18]
and eax, 0xfffffffb
or eax, 3
push esi
mov dword [edx + 0x18], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
test ebx, ebx
je 0x4ffa58
push ebx
call fcn.004fedb0
mov ecx, dword [edx + 0x18]
add esp, 4
and ecx, 0xfffffff8
or eax, ecx
mov dword [edx + 0x18], eax
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005b26e6
mov esp, ebp
pop ebp
ret
mov edi, 0x8007000d
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.005b26e6
mov esp, ebp
pop ebp
ret