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

Disassembly:
mov eax, 0x43342c
call fcn.00425dc8
sub esp, 0x48
push ebx
xor ebx, ebx
cmp dword [ecx + 0x10c], ebx
push esi
push edi
mov dword [ebp - 0x28], ecx
je 0x41e63b
cmp dword [ebp + 8], ebx
je 0x41e63b
mov esi, dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, 0x80
push ebx
push edi
push 3
push ebx
push 3
add ecx, 4
push SysReAllocStringLen
push ecx
call esi
cmp eax, 0xffffffff
mov dword [ebp - 0x24], eax
jne 0x41e64e
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 0x28]
mov dword [ecx + 0x118], eax
xor eax, eax
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 0x10
mov ecx, dword [ebp - 0x28]
push ebx
push ebx
push dword [ebp + 0xc]
push eax
call fcn.0041eb86
test eax, eax
je 0x41e63b
push ebx
push edi
push 2
push ebx
push ebx
push 0x40000000
push dword [ebp + 0x10]
call esi
cmp eax, 0xffffffff
mov dword [ebp - 0x2c], eax
jne 0x41e692
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 0x28]
push dword [ebp - 0x24]
mov dword [ecx + 0x118], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x41e63b
mov esi, dword [ebp + 8]
mov eax, 0x400
mov dword [ebp - 0x1c], eax
mov edi, dword [esi + 0x10c]
cmp edi, eax
mov dword [ebp - 0x18], edi
jae 0x41e6ad
mov dword [ebp - 0x1c], edi
push dword [ebp - 0x1c]
call fcn.00425de7
mov dword [ebp - 0x20], eax
mov eax, dword [esi + 0x104]
test al, 6
pop ecx
mov byte [ebp + 0xf], bl
je 0x41e6ca
mov byte [ebp + 0xf], 1
mov esi, dword [ebp + 0x14]
mov dword [ebp - 0x28], 1
shr al, 2
and al, 1
cmp esi, ebx
mov byte [ebp - 0xd], al
je 0x41e6f0
mov eax, dword [esi]
push edi
push ebx
mov ecx, esi
call dword [eax]
cmp al, bl
jne 0x41e781
lea eax, [ebp - 0x14]
push ebx
push eax
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x1c]
mov dword [ebp + 0x14], ebx
push dword [ebp - 0x20]
push dword [ebp - 0x24]
call edi
test eax, eax
je 0x41e784
cmp byte [ebp - 0xd], bl
je 0x41e728
cmp byte [ebp + 0xf], bl
je 0x41e728
push dword [ebp + 8]
push dword [ebp - 0x14]
push dword [ebp - 0x20]
call fcn.004013aa
add esp, 0xc
lea eax, [ebp - 0x14]
push ebx
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x20]
push dword [ebp - 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x14]
add dword [ebp + 0x14], eax
cmp esi, ebx
je 0x41e756
push dword [ebp - 0x18]
mov eax, dword [esi]
mov ecx, esi
push dword [ebp + 0x14]
call dword [eax]
cmp al, bl
jne 0x41e781
mov eax, dword [ebp - 0x14]
sub dword [ebp - 0x18], eax
je 0x41e784
cmp eax, ebx
je 0x41e784
cmp dword [ebp - 0x18], 0x400
jae 0x41e771
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x14]
push ebx
push eax
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x24]
jmp 0x41e707
mov dword [ebp - 0x28], ebx
push dword [ebp - 0x24]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x2c]
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
push dword [ebp - 0x2c]
call esi
cmp dword [ebp - 0x28], ebx
je 0x41e7de
cmp byte [ebp - 0xd], bl
jne 0x41e7de
cmp byte [ebp + 0xf], bl
je 0x41e7de
lea eax, [ebp + 0x13]
push 1
push eax
lea ecx, [ebp - 0x54]
push dword [ebp + 0x10]
call fcn.004014ff
mov ecx, eax
mov dword [ebp - 4], ebx
call fcn.004016f0
push dword [ebp + 8]
push eax
call fcn.00401408
or dword [ebp - 4], 0xffffffff
pop ecx
pop ecx
lea ecx, [ebp - 0x54]
call fcn.0040191f
push dword [ebp - 0x20]
call fcn.0042541c
mov eax, dword [ebp - 0x28]
pop ecx
jmp 0x41e63d