Function at 0x412db0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0xc]
test esi, esi
je 0x412fe6
cmp byte [esi + 0x5c], 0x72
jne 0x412fe6
mov eax, dword [esi + 0x38]
cmp eax, 0xfffffffd
je 0x412fdd
cmp eax, 0xffffffff
je 0x412fdd
cmp eax, 1
jne 0x412def
pop edi
xor eax, eax
pop esi
pop ebp
ret 0xc
push ebx
mov ebx, dword [ebp + 0x10]
mov dword [ebp + 0xc], edi
mov dword [esi + 0xc], edi
mov dword [esi + 0x10], ebx
test ebx, ebx
je 0x412e3a
cmp dword [esi + 0x6c], 0xffffffff
je 0x412e3a
mov al, byte [esi + 0x6c]
mov byte [edi], al
inc dword [esi + 0xc]
dec dword [esi + 0x10]
inc dword [esi + 0x68]
cmp dword [esi + 0x70], 0
lea eax, [edi + 1]
mov dword [ebp + 0xc], eax
mov dword [esi + 0x6c], 0xffffffff
je 0x412e3a
pop ebx
pop edi
mov dword [esi + 0x38], 1
mov eax, 1
pop esi
pop ebp
ret 0xc
cmp dword [esi + 0x10], 0
je 0x412f3d
cmp dword [esi + 0x58], 0
jne 0x412f76
cmp dword [esi + 4], 0
jne 0x412eb3
cmp dword [esi + 0x3c], 0
jne 0x412eb3
call fcn.0052f9bd
mov dword [eax], 0
push dword [esi + 0x40]
push 0x4000
push 1
push dword [esi + 0x44]
call fcn.0052ce49
add esp, 0x10
mov dword [esi + 4], eax
test eax, eax
jne 0x412eae
push dword [esi + 0x40]
mov dword [esi + 0x3c], 1
call fcn.0052dcbb
add esp, 4
test eax, eax
jne 0x412f64
push dword [esi + 0x40]
call fcn.0052dc95
add esp, 4
test eax, eax
jne 0x412f5b
mov eax, dword [esi + 0x44]
mov dword [esi], eax
mov eax, dword [esi + 4]
add dword [esi + 0x64], eax
mov eax, dword [esi + 0x10]
add dword [esi + 0x68], eax
push 0
push esi
call fcn.004144f0
mov ecx, dword [esi + 4]
sub dword [esi + 0x64], ecx
mov ecx, dword [esi + 0x10]
sub dword [esi + 0x68], ecx
mov dword [esi + 0x38], eax
cmp eax, 1
jne 0x412f27
mov eax, dword [esi + 0xc]
sub eax, edi
push eax
push edi
push dword [esi + 0x4c]
call fcn.00415b90
mov edi, dword [esi + 0xc]
push esi
mov dword [esi + 0x4c], eax
call fcn.004129a0
add esp, 4
cmp eax, dword [esi + 0x4c]
jne 0x412f6d
push esi
call fcn.004129a0
push esi
call fcn.004126b0
add esp, 8
cmp dword [esi + 0x38], 0
jne 0x412f3d
push esi
call fcn.00415a00
push 0
push 0
push 0
call fcn.00415b90
mov dword [esi + 0x4c], eax
cmp dword [esi + 0x38], 0
jne 0x412f3d
cmp dword [esi + 0x3c], 0
jne 0x412f3d
cmp dword [esi + 0x10], 0
jne 0x412e44
mov eax, dword [esi + 0xc]
sub eax, edi
push eax
push edi
push dword [esi + 0x4c]
call fcn.00415b90
sub ebx, dword [esi + 0x10]
mov dword [esi + 0x4c], eax
mov eax, ebx
pop ebx
pop edi
pop esi
pop ebp
ret 0xc
mov dword [esi + 0x38], 1
jmp 0x412f3d
mov dword [esi + 0x38], 0xffffffff
jmp 0x412f3d
mov dword [esi + 0x38], 0xfffffffd
jmp 0x412f3d
mov edi, dword [esi + 4]
cmp edi, dword [esi + 0x10]
cmova edi, dword [esi + 0x10]
test edi, edi
je 0x412fa4
push edi
push dword [esi]
push dword [esi + 0xc]
call fcn.0052fa20
mov ecx, dword [ebp + 0xc]
add dword [esi], edi
sub dword [esi + 0x10], edi
add ecx, edi
add esp, 0xc
sub dword [esi + 4], edi
mov dword [esi + 0xc], ecx
jmp 0x412fa7
mov ecx, dword [ebp + 0xc]
mov eax, dword [esi + 0x10]
test eax, eax
je 0x412fc0
push dword [esi + 0x40]
push eax
push 1
push ecx
call fcn.0052ce49
add esp, 0x10
sub dword [esi + 0x10], eax
sub ebx, dword [esi + 0x10]
add dword [esi + 0x64], ebx
add dword [esi + 0x68], ebx
test ebx, ebx
jne 0x412f52
mov eax, ebx
pop ebx
pop edi
mov dword [esi + 0x3c], 1
pop esi
pop ebp
ret 0xc
pop edi
or eax, 0xffffffff
pop esi
pop ebp
ret 0xc
pop edi
mov eax, 0xfffffffe
pop esi
pop ebp
ret 0xc