Function at 0x41c465
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
push ebx
push esi
mov ebx, ecx
mov eax, dword [ebx + 0x2bc]
push edi
xor esi, esi
xor edi, edi
test eax, eax
jne 0x41c485
xor al, al
jmp 0x41c683
jbe 0x41c4cf
mov esi, dword [ebx + 0x2d4]
add esi, edi
cmp dword [esi], 0x2014b50
jne 0x41c47e
push dword [ebp + 8]
call fcn.00428940
push eax
lea eax, [esi + 0x2e]
push eax
push dword [ebp + 8]
call fcn.00429e48
add esp, 0x10
test eax, eax
je 0x41c4cf
movzx ecx, word [esi + 0x1e]
movzx eax, word [esi + 0x20]
add eax, ecx
movzx ecx, word [esi + 0x1c]
add ecx, edi
lea edi, [ecx + eax + 0x2e]
cmp edi, dword [ebx + 0x2bc]
jb 0x41c487
cmp edi, dword [ebx + 0x2bc]
jae 0x41c47e
cmp dword [esi], 0x2014b50
mov dword [ebp - 4], edi
jne 0x41c47e
lea eax, [ebx + 0xc]
push 0x45e9a0
push eax
call fcn.0042ac8a
mov edi, eax
pop ecx
pop ecx
mov dword [ebp + 8], edi
test edi, edi
je 0x41c47e
push 2
push 0
push edi
call fcn.0043099a
push edi
call fcn.00431369
add esp, 0x10
cmp eax, 0x62
jae 0x41c51f
push edi
call fcn.0042a9b7
pop ecx
jmp 0x41c47e
push 0
push dword [esi + 0x2a]
push edi
call fcn.0043099a
push edi
push 1
lea eax, [ebp - 0x28]
push 0x1e
push eax
call fcn.004311af
movzx eax, word [ebp - 0xe]
add eax, dword [ebp - 0x16]
add esp, 0x1c
push 0xb
pop ecx
lea edi, [ebp - 0x58]
rep movsd dword es:[edi], dword [esi]
movzx ecx, word [ebp - 0xc]
movsw word es:[edi], word [esi]
lea esi, [ecx + eax + 0x1e]
movzx ecx, word [ebp - 0x3c]
mov eax, dword [ebp - 0x3c]
shr eax, 0x10
add eax, ecx
movzx ecx, word [ebp - 0x38]
lea edi, [eax + ecx + 0x2e]
mov eax, dword [ebp - 0x2e]
push eax
add eax, esi
push eax
push dword [ebp + 8]
mov ecx, ebx
call fcn.0041c30a
xor ecx, ecx
mov dword [ebp - 8], ecx
cmp dword [ebx + 0x2bc], ecx
jbe 0x41c5bb
mov eax, dword [ebx + 0x2d4]
add eax, ecx
mov ecx, dword [eax + 0x2a]
cmp ecx, dword [ebp - 0x2e]
jbe 0x41c59b
sub ecx, esi
mov dword [eax + 0x2a], ecx
movzx ecx, word [eax + 0x20]
movzx edx, word [eax + 0x1e]
movzx eax, word [eax + 0x1c]
add eax, dword [ebp - 8]
add ecx, edx
lea ecx, [eax + ecx + 0x2e]
mov dword [ebp - 8], ecx
cmp ecx, dword [ebx + 0x2bc]
jb 0x41c586
mov eax, dword [ebx + 0x2c0]
push 0
sub eax, esi
push eax
push dword [ebp + 8]
call fcn.0043099a
add esp, 0xc
cmp dword [ebp - 4], 0
je 0x41c5ed
push dword [ebp + 8]
push 1
push dword [ebp - 4]
push dword [ebx + 0x2d4]
call fcn.00430820
add esp, 0x10
mov eax, dword [ebx + 0x2bc]
push dword [ebp + 8]
sub eax, edi
sub eax, dword [ebp - 4]
push 1
push eax
mov eax, dword [ebx + 0x2d4]
add eax, edi
add eax, dword [ebp - 4]
push eax
call fcn.00430820
push dword [ebp + 8]
sub dword [ebx + 0x2bc], edi
sub dword [ebx + 0x2c0], esi
mov eax, 0xffff
add word [ebx + 0x2ba], ax
mov ecx, eax
add word [ebx + 0x2b8], cx
xor eax, eax
push 1
mov word [ebx + 0x2c4], ax
lea eax, [ebx + 0x2b0]
push 0x16
push eax
call fcn.00430820
push dword [ebp + 8]
call fcn.00431369
push dword [ebp + 8]
mov esi, eax
call fcn.0042a9b7
add esp, 0x28
push esi
lea esi, [ebx + 0xc]
push esi
mov ecx, ebx
call fcn.0041c3eb
push esi
mov ecx, ebx
call fcn.0041b9c6
mov eax, dword [ebx + 0x2d0]
mov dword [ebx + 0x2cc], eax
mov al, 1
pop edi
pop esi
pop ebx
leave
ret 4