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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x402a7b
mov eax, dword fs:[0]
push eax
sub esp, 0x48c
mov eax, dword [0x404018]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea ecx, [ebp - 0x48c]
call fcn.00401550
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x48c]
mov esi, dword [eax - 0xc]
lea edx, [ebp - 0x250]
sub edx, eax
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
test cx, cx
jne 0x401771
lea eax, [ebp - 0x50]
push eax
mov eax, str.hVwuenTuxssxclw:5
call fcn.00401220
lea ecx, [ebp + esi*2 - 0x250]
push ecx
lea ebx, [ebp - 0x50]
call fcn.004016a0
lea edx, [ebp - 0x450]
push edx
mov eax, str.ejnygyuqp__1mpm
call fcn.00401220
lea eax, [ebp + esi*2 - 0x22c]
push eax
lea ebx, [ebp - 0x450]
call fcn.004016a0
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x48c]
add eax, 0xfffffff0
add esp, 0x10
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4017ee
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ebx, dword [sym.imp.MSVCR100.dll__wfopen]
lea ecx, [ebp - 0x250]
push 0x4031f8
push ecx
call ebx
add esp, 8
test eax, eax
je 0x40196f
mov edi, dword [sym.imp.MSVCR100.dll_fclose]
push eax
call edi
lea edx, [ebp - 0x250]
push 0x40321c
push edx
call ebx
mov esi, eax
add esp, 0xc
test esi, esi
je 0x401aa1
push esi
push 1
lea eax, [ebp - 0x488]
push 0x1c
push eax
call dword [sym.imp.MSVCR100.dll_fread]
push esi
call edi
lea ecx, [ebp - 0x488]
call fcn.00401400
push 0
call dword [sym.imp.MSVCR100.dll__time64]
lea ecx, [ebp - 0x490]
push ecx
mov dword [ebp - 0x490], eax
mov dword [ebp - 0x48c], edx
call dword [sym.imp.MSVCR100.dll__localtime64]
mov edx, dword [eax + 0x14]
add edx, 0x76c
mov dword [ebp - 0x45c], edx
mov ecx, dword [eax + 0x10]
inc ecx
mov dword [ebp - 0x460], ecx
mov edx, dword [eax + 0xc]
mov dword [ebp - 0x458], edx
mov ecx, dword [eax + 8]
mov dword [ebp - 0x464], ecx
mov edx, dword [eax + 4]
mov dword [ebp - 0x468], edx
mov ecx, dword [eax]
mov dword [ebp - 0x46c], ecx
mov ecx, dword [eax + 0x14]
imul ecx, ecx, 0xd
add ecx, dword [eax + 0x10]
add esp, 0x1c
mov edx, ecx
shl edx, 5
sub edx, ecx
add edx, dword [eax + 0xc]
mov ecx, dword [eax + 8]
lea edx, [edx + edx*2]
lea ecx, [ecx + edx*8]
mov edx, ecx
shl edx, 4
sub edx, ecx
mov ecx, dword [eax + 4]
lea ecx, [ecx + edx*4]
mov edx, ecx
shl edx, 4
sub edx, ecx
mov ecx, dword [eax]
lea ecx, [ecx + edx*4 + 0xb439b80]
mov dword [ebp - 0x454], ecx
cmp ecx, dword [ebp - 0x470]
jl 0x401aa1
mov ecx, dword [eax + 0x14]
cmp ecx, 0x77
jl 0x401aa1
mov edx, 4
jne 0x40192c
cmp dword [eax + 0x10], edx
jl 0x401aa1
cmp ecx, 0x77
jne 0x40192c
cmp dword [eax + 0x10], edx
jne 0x40192c
cmp dword [eax + 0xc], 0xe
jl 0x401aa1
lea edx, [ebp - 0x250]
push 0x403224
push edx
call ebx
mov esi, eax
add esp, 8
test esi, esi
je 0x401aa1
lea ecx, [ebp - 0x46c]
call fcn.004012c0
push esi
push 1
lea eax, [ebp - 0x46c]
push 0x1c
push eax
call dword [sym.imp.MSVCR100.dll_fwrite]
push esi
call edi
add esp, 0x14
jmp 0x401aa1
mov ecx, dword [sym.imp.MSVCR100.dll__fmode]
lea edx, [ebp - 0x250]
push 0x403200
push edx
mov dword [ecx], 0x8000
call ebx
add esp, 8
test eax, eax
je 0x401aa1
mov edi, dword [sym.imp.MSVCR100.dll_fclose]
push eax
call edi
lea eax, [ebp - 0x250]
push 0x403224
push eax
call ebx
mov esi, eax
add esp, 0xc
test esi, esi
je 0x401aa1
push 0
call dword [sym.imp.MSVCR100.dll__time64]
lea ecx, [ebp - 0x498]
push ecx
mov dword [ebp - 0x498], eax
mov dword [ebp - 0x494], edx
call dword [sym.imp.MSVCR100.dll__localtime64]
mov edx, dword [eax + 0x14]
add edx, 0x76c
mov dword [ebp - 0x45c], edx
mov ecx, dword [eax + 0x10]
inc ecx
mov dword [ebp - 0x460], ecx
mov edx, dword [eax + 0xc]
mov dword [ebp - 0x458], edx
mov ecx, dword [eax + 8]
mov dword [ebp - 0x464], ecx
mov edx, dword [eax + 4]
mov dword [ebp - 0x468], edx
mov ecx, dword [eax]
mov dword [ebp - 0x46c], ecx
mov ecx, dword [eax + 0x14]
imul ecx, ecx, 0xd
add ecx, dword [eax + 0x10]
add esp, 8
mov edx, ecx
shl edx, 5
sub edx, ecx
add edx, dword [eax + 0xc]
mov ecx, dword [eax + 8]
lea edx, [edx + edx*2]
lea ecx, [ecx + edx*8]
mov edx, ecx
shl edx, 4
sub edx, ecx
mov ecx, dword [eax + 4]
lea ecx, [ecx + edx*4]
mov edx, ecx
shl edx, 4
sub edx, ecx
mov ecx, dword [eax]
lea edx, [ecx + edx*4 + 0xb439b80]
mov dword [ebp - 0x454], edx
mov ecx, dword [eax + 0x14]
cmp ecx, 0x77
jl 0x401a9b
mov edx, 4
jne 0x401a7b
cmp dword [eax + 0x10], edx
jl 0x401a9b
cmp ecx, 0x77
jne 0x401a7b
cmp dword [eax + 0x10], edx
jne 0x401a7b
cmp dword [eax + 0xc], 0xe
jl 0x401a9b
lea ecx, [ebp - 0x46c]
call fcn.004012c0
push esi
push 1
lea eax, [ebp - 0x46c]
push 0x1c
push eax
call dword [sym.imp.MSVCR100.dll_fwrite]
add esp, 0x10
push esi
call edi
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00401de2
mov esp, ebp
pop ebp
ret