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

Disassembly:
push 0xffffffffffffffff
push 0x416760
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push ebp
push esi
push edi
mov eax, dword [0x41c350]
xor eax, esp
push eax
lea eax, [esp + 0x24]
mov dword fs:[0], eax
mov esi, dword [esp + 0x34]
push 0x4172f4
push esi
mov dword [esp + 0x34], 1
call fcn.004070ec
mov edi, dword [esp + 0x40]
push 0x4172f0
push edi
mov ebx, eax
call fcn.004070ec
add esp, 0x10
test ebx, ebx
mov ebp, eax
mov dword [esp + 0x14], ebp
je 0x401ba9
test ebp, ebp
je 0x401ba6
push 2
push 0
push ebx
call fcn.00406fa3
add esp, 0xc
test eax, eax
push ebx
je 0x401942
call fcn.00406ea0
push ebp
call fcn.00406ea0
lea eax, [esi - 0x10]
add esp, 8
mov byte [esp + 0x2c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x401bcb
call fcn.00406dc0
mov edi, eax
add esp, 4
cmp edi, 1
jg 0x401977
push ebx
call fcn.00406ea0
push ebp
call fcn.00406ea0
add esp, 8
lea ecx, [esp + 0x34]
call fcn.004016c0
lea ecx, [esp + 0x38]
call fcn.004016c0
jmp 0x401bf7
push 0
push 0
push ebx
call fcn.00406fa3
add esp, 0xc
test eax, eax
jne 0x401951
mov eax, str.we86590__asdftughjk5748rhj7890fdgh04C2F69hgjD3B_jk_l2Fu__q
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x401990
sub eax, edx
add eax, edi
push eax
call fcn.00406c23
add esp, 4
mov ebp, eax
test ebp, ebp
push ebx
jne 0x4019b9
call fcn.00406ea0
mov ecx, dword [esp + 0x18]
push ecx
jmp 0x401958
push edi
push 1
push ebp
call fcn.00406c08
add esp, 0x10
cmp eax, edi
je 0x4019e7
push ebx
call fcn.00406ea0
mov edx, dword [esp + 0x18]
push edx
call fcn.00406ea0
push ebp
call fcn.00406967
add esp, 0xc
jmp 0x401960
lea esi, [edi + ebp]
mov dword [esp + 0x20], esi
add esi, 0xffffffe0
push 0x20
push esi
lea ecx, [esp + 0x24]
call fcn.004017d0
mov eax, str.we86590__asdftughjk5748rhj7890fdgh04C2F69hgjD3B_jk_l2Fu__q
mov byte [esp + 0x2c], 2
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x401a10
sub eax, edx
push eax
push str.we86590__asdftughjk5748rhj7890fdgh04C2F69hgjD3B_jk_l2Fu__q
push esi
call fcn.004074d0
mov eax, str.we86590__asdftughjk5748rhj7890fdgh04C2F69hgjD3B_jk_l2Fu__q
add esp, 0xc
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x401a32
sub eax, edx
lea eax, [eax + edi - 0x20]
push eax
lea ecx, [esp + 0x1c]
push ebp
push ecx
call fcn.00405910
lea edx, [esp + 0x24]
push edx
lea eax, [esp + 0x2c]
push eax
mov byte [esp + 0x40], 3
call fcn.004016e0
add esp, 0x14
test al, al
je 0x401a88
push ebp
call fcn.00406967
add esp, 4
lea ecx, [esp + 0x18]
call fcn.004016c0
lea ecx, [esp + 0x1c]
call fcn.004016c0
jmp 0x401960
mov esi, ebp
xor edi, edi
lea esp, [esp]
mov ecx, dword [esp + 0x20]
push str.___________________________7d70000000000
push ecx
push esi
call fcn.004011b0
mov esi, eax
add esp, 0xc
test esi, esi
je 0x401afb
mov eax, str.___________________________7d70000000000
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x401ab1
sub eax, edx
add edi, 1
add esi, eax
cmp edi, 7
jl 0x401a90
mov eax, dword [esp + 0x20]
push str.___________________________7d70000000000
push eax
push esi
call fcn.004011b0
add esp, 0xc
test eax, eax
jne 0x401b19
push ebx
call fcn.00406ea0
mov ecx, dword [esp + 0x18]
push ecx
call fcn.00406ea0
push ebp
call fcn.00406967
add esp, 0xc
jmp 0x401a71
push ebx
call fcn.00406ea0
mov edx, dword [esp + 0x18]
push edx
call fcn.00406ea0
push ebp
call fcn.00406967
add esp, 0xc
jmp 0x401a71
mov edx, dword [esp + 0x14]
sub eax, esi
push edx
mov edi, eax
push edi
push 1
push esi
call fcn.004068e5
add esp, 0x10
cmp eax, edi
je 0x401b50
push ebx
call fcn.00406ea0
mov eax, dword [esp + 0x18]
push eax
call fcn.00406ea0
push ebp
call fcn.00406967
add esp, 0xc
jmp 0x401a71
push ebp
call fcn.00406967
push ebx
call fcn.00406ea0
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.00406ea0
add esp, 0xc
lea ecx, [esp + 0x18]
call fcn.004016c0
lea ecx, [esp + 0x1c]
call fcn.004016c0
lea ecx, [esp + 0x34]
call fcn.004016c0
lea ecx, [esp + 0x38]
call fcn.004016c0
mov eax, 1
mov ecx, dword [esp + 0x24]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret
push ebx
jmp 0x401bae
test ebp, ebp
je 0x401bb6
push ebp
call fcn.00406ea0
add esp, 4
lea eax, [esi - 0x10]
mov byte [esp + 0x2c], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x401bd7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [edi - 0x10]
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov dword [esp + 0x2c], edx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401bf7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
mov ecx, dword [esp + 0x24]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret