Function at 0x47d370
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x84
mov eax, dword [0x641a90]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x84]
push edi
mov edi, dword [ebp + 8]
push dword [edi]
push 1
push 8
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x7c], 0
push eax
call fcn.00593e1b
add esp, 4
mov dword [esi], eax
cmp eax, 3
jne 0x47d6e8
push dword [edi]
lea eax, [ebp - 0x84]
push 1
push 8
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x7c], 0
push eax
call fcn.00593e1b
add esp, 4
mov dword [esi + 4], eax
cmp eax, 0x400
jne 0x47d6e8
push dword [edi]
lea eax, [ebp - 0x84]
push 1
push 8
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x7c], 0
push eax
call fcn.00593e1b
mov dword [esi + 8], eax
lea eax, [ebp - 0x84]
push dword [edi]
push 1
push 8
push eax
call fcn.00595b79
add esp, 0x14
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x7c], 0
push eax
call fcn.00593e1b
mov ecx, dword [esi + 8]
add esp, 4
mov dword [esi + 0xc], eax
test ecx, ecx
js 0x47d6e8
cmp ecx, 0x3e80
jg 0x47d6e8
test eax, eax
js 0x47d6e8
cmp eax, 0x3e80
jg 0x47d6e8
push dword [edi]
lea eax, [ebp - 0x84]
push 1
push 8
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x7c], 0
push eax
call fcn.00593e1b
mov dword [esi + 0x10], eax
lea eax, [ebp - 0x84]
push dword [edi]
push 1
push 3
push eax
call fcn.00595b79
add esp, 0x14
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x81], 0
push eax
call fcn.00593e1b
add esp, 4
mov dword [esi + 0x14], eax
cmp eax, 1
je 0x47d505
cmp eax, 3
jne 0x47d6e8
push dword [edi]
lea eax, [ebp - 0x84]
push 1
push 5
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x7f], 0
push eax
call fcn.00593e1b
add esp, 4
mov dword [esi + 0x18], eax
test eax, eax
jne 0x47d55f
cmp dword [esi + 0x20], 1
jne 0x47d559
cmp dword [esi + 0x14], 1
jne 0x47d559
mov eax, dword [esi + 8]
add eax, 7
cdq
and edx, 7
add eax, edx
sar eax, 3
jmp 0x47d55c
mov eax, dword [esi + 8]
mov dword [esi + 0x18], eax
push dword [edi]
lea eax, [ebp - 0x84]
push 1
push 4
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x80], 0
push eax
call fcn.00593e1b
mov dword [esi + 0x1c], eax
lea eax, [ebp - 0x84]
push dword [edi]
push 1
push 4
push eax
call fcn.00595b79
add esp, 0x14
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x80], 0
push eax
call fcn.00593e1b
add esp, 4
mov dword [esi + 0x20], eax
test eax, eax
je 0x47d5d2
cmp eax, 0x18
jne 0x47d5d9
mov dword [esi + 0x14], 3
mov dword [esi + 0x20], 8
mov eax, dword [esi + 0x20]
cmp eax, 1
je 0x47d5ea
cmp eax, 8
jne 0x47d6e8
push dword [edi]
lea eax, [ebp - 0x84]
push 1
push 4
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x80], 0
push eax
call fcn.00593e1b
mov dword [esi + 0x24], eax
lea eax, [ebp - 0x84]
push dword [edi]
push 1
push 4
push eax
call fcn.00595b79
add esp, 0x14
test eax, eax
je 0x47d6e8
lea eax, [ebp - 0x84]
mov byte [ebp - 0x80], 0
push eax
call fcn.00593e1b
mov dword [esi + 0x28], eax
lea eax, [esi + 0x2c]
push dword [edi]
push 1
push 0x30
push eax
call fcn.00595b79
add esp, 0x14
test eax, eax
jne 0x47d675
pop edi
mov eax, 4
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
push dword [edi]
lea eax, [esi + 0x5c]
push 1
push 0x20
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d660
push dword [edi]
lea eax, [esi + 0x7c]
push 1
push 0x10
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d660
push dword [edi]
lea eax, [esi + 0x8c]
push 1
push 0x60
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d660
push dword [edi]
lea eax, [esi + 0xec]
push 1
push 0x300
push eax
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x47d660
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov eax, 2
pop edi
xor ecx, ebp
pop esi
call fcn.005920c1
mov esp, ebp
pop ebp
ret