Function at 0x53e880
Capabilities:
Read file on windows

Disassembly:
push ecx
mov ecx, dword [esp + 0xc]
push ebx
push ebp
mov ebp, dword [esp + 0x10]
push esi
push edi
test ebp, ebp
mov esi, ecx
je 0x53eaa4
cmp byte [ebp + 0x5c], 0x72
jne 0x53eaa4
mov eax, dword [ebp + 0x38]
cmp eax, 0xfffffffd
je 0x53ea9b
cmp eax, 0xffffffff
je 0x53ea9b
cmp eax, 1
jne 0x53e8c3
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
mov ebx, dword [esp + 0x20]
mov dword [esp + 0x10], ecx
test ebx, ebx
mov dword [ebp + 0xc], ecx
mov dword [ebp + 0x10], ebx
je 0x53ea78
mov eax, dword [ebp + 0x58]
test eax, eax
mov eax, dword [ebp + 4]
jne 0x53e9de
test eax, eax
jne 0x53e935
mov eax, dword [ebp + 0x3c]
test eax, eax
jne 0x53e935
call fcn.005658a7
mov dword [eax], 0
mov eax, dword [ebp + 0x40]
mov ecx, dword [ebp + 0x44]
push eax
push 0x4000
push 1
push ecx
call fcn.00567932
add esp, 0x10
mov dword [ebp + 4], eax
test eax, eax
jne 0x53e92f
mov edx, dword [ebp + 0x40]
mov dword [ebp + 0x3c], 1
test byte [edx + 0xc], 0x20
jne 0x53ea71
mov eax, dword [ebp + 0x44]
mov dword [ebp], eax
push 0
push ebp
call fcn.0053f250
add esp, 8
cmp eax, 1
mov dword [ebp + 0x38], eax
jne 0x53e9b8
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x4c]
sub ecx, esi
push ecx
push esi
push edx
call fcn.00540990
mov dword [ebp + 0x4c], eax
mov eax, dword [ebp + 0xc]
push ebp
mov dword [esp + 0x28], eax
call fcn.0053eec0
mov ecx, dword [ebp + 0x4c]
add esp, 0x10
cmp eax, ecx
je 0x53e97b
mov dword [ebp + 0x38], 0xfffffffd
jmp 0x53e9b4
push ebp
call fcn.0053eec0
push ebp
call fcn.0053e5f0
mov eax, dword [ebp + 0x38]
add esp, 8
test eax, eax
jne 0x53e9b4
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0x14]
push ebp
call fcn.0053f0a0
push 0
push 0
push 0
mov dword [ebp + 8], esi
mov dword [ebp + 0x14], edi
call fcn.00540990
add esp, 0x10
mov dword [ebp + 0x4c], eax
mov esi, dword [esp + 0x18]
mov eax, dword [ebp + 0x38]
test eax, eax
jne 0x53ea78
mov eax, dword [ebp + 0x3c]
test eax, eax
jne 0x53ea78
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x53e8d9
jmp 0x53ea78
mov ecx, dword [ebp + 0x10]
cmp eax, ecx
jbe 0x53e9e7
mov eax, ecx
test eax, eax
jbe 0x53ea26
mov esi, dword [ebp]
mov edi, dword [ebp + 0xc]
mov ecx, eax
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x1c]
mov esi, dword [ebp]
mov edx, dword [ebp + 0x10]
add ecx, eax
mov dword [esp + 0x10], ecx
mov dword [ebp + 0xc], ecx
mov ecx, dword [ebp + 4]
add esi, eax
sub edx, eax
sub ecx, eax
mov dword [ebp], esi
mov dword [ebp + 0x10], edx
mov dword [ebp + 4], ecx
mov eax, dword [ebp + 0x10]
test eax, eax
jbe 0x53ea49
mov edx, dword [ebp + 0x40]
push edx
push eax
mov eax, dword [esp + 0x18]
push 1
push eax
call fcn.00567932
mov ecx, dword [ebp + 0x10]
add esp, 0x10
sub ecx, eax
mov dword [ebp + 0x10], ecx
mov esi, dword [ebp + 0x10]
mov edx, dword [ebp + 8]
mov ecx, dword [ebp + 0x14]
sub ebx, esi
add edx, ebx
add ecx, ebx
test ebx, ebx
mov dword [ebp + 8], edx
mov dword [ebp + 0x14], ecx
jne 0x53ea69
mov dword [ebp + 0x3c], 1
pop edi
pop esi
mov eax, ebx
pop ebp
pop ebx
pop ecx
ret
mov dword [ebp + 0x38], 0xffffffff
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x4c]
sub ecx, esi
push ecx
push esi
push edx
call fcn.00540990
mov ecx, dword [ebp + 0x10]
add esp, 0xc
mov dword [ebp + 0x4c], eax
mov eax, ebx
pop edi
pop esi
pop ebp
sub eax, ecx
pop ebx
pop ecx
ret
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
pop ecx
ret
pop edi
pop esi
pop ebp
mov eax, 0xfffffffe
pop ebx
pop ecx
ret