Function at 0x401748
Capabilities:
Delete file
Read file on windows
Write file on windows

Disassembly:
push ebx
push esi
push edi
push ebp
lea eax, [esi + 0x800]
test eax, 0xfff
je 0x401763
and eax, 0xfffff000
add eax, 0x1000
mov dword [edi + 0x44], eax
lea eax, [edi + 0x800]
test eax, 0xfff
je 0x40177d
and eax, 0xfffff000
add eax, 0x1000
mov dword [edi + 0x48], eax
cld
xor eax, eax
mov ecx, 0xe
rep stosd dword es:[edi], eax
xor eax, eax
push eax
push dword [esi + 0x18]
push 2
push eax
push eax
push 0xc0000000
lea eax, [esi + 0x30]
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileA]
test eax, eax
je 0x401985
xchg ebx, eax
lea eax, [edi - 0x10]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemTimeAsFileTime]
mov eax, dword [esi + 0x28]
mov dword [edi + 8], eax
mov eax, dword [esi + 0x10]
mov dword [edi + 4], eax
mov eax, dword [esi + 8]
mov dword [edi], eax
mov eax, dword [edi + 0xc]
mov dword [edi + 0x14], eax
xor eax, eax
push eax
lea ecx, [edi - 0x18]
push ecx
mov dword [ecx], eax
mov dword [ecx + 4], eax
push dword [edi]
push dword [edi + 0x14]
push ebx
call dword [sym.imp.KERNEL32.DLL_WriteFile]
test eax, eax
je 0x401985
mov eax, dword [edi - 0x18]
add dword [edi + 0x14], eax
sub dword [edi], eax
jne 0x4017cd
dec dword [edi + 4]
jne 0x4017c2
xor eax, eax
push eax
push eax
push eax
push ebx
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
dec dword [edi + 8]
jne 0x4017bc
lea eax, [edi - 8]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemTimeAsFileTime]
mov eax, dword [edi - 8]
mov edx, dword [edi - 4]
sub eax, dword [edi - 0x10]
sbb edx, dword [edi - 0xc]
mov dword [edi - 0x38], eax
mov dword [edi - 0x34], edx
lea eax, [edi - 0x10]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemTimeAsFileTime]
mov eax, dword [esi + 0x28]
mov dword [edi + 8], eax
mov eax, dword [esi + 0x10]
mov dword [edi + 4], eax
mov eax, dword [esi + 8]
mov dword [edi], eax
mov eax, dword [edi + 0x10]
mov dword [edi + 0x14], eax
xor eax, eax
push eax
lea ecx, [edi - 0x18]
push ecx
mov dword [ecx], eax
mov dword [ecx + 4], eax
push dword [edi]
push dword [edi + 0x14]
push ebx
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x401985
mov eax, dword [edi - 0x18]
add dword [edi + 0x14], eax
sub dword [edi], eax
jne 0x40184a
dec dword [edi + 4]
jne 0x40183f
xor eax, eax
push eax
push eax
push eax
push ebx
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
dec dword [edi + 8]
jne 0x401839
lea eax, [edi - 8]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemTimeAsFileTime]
mov eax, dword [edi - 8]
mov edx, dword [edi - 4]
sub eax, dword [edi - 0x10]
sbb edx, dword [edi - 0xc]
mov dword [edi - 0x30], eax
mov dword [edi - 0x2c], edx
xor eax, eax
push eax
push dword [esi + 0x20]
push 2
push eax
push eax
push 0xc0000000
lea ecx, [esi + 0x400]
push ecx
call dword [sym.imp.KERNEL32.DLL_CreateFileA]
test eax, eax
je 0x401985
xchg ebp, eax
lea eax, [edi - 0x10]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemTimeAsFileTime]
mov eax, dword [esi + 0x28]
mov dword [edi + 8], eax
mov eax, dword [esi + 0x10]
mov dword [edi + 4], eax
mov eax, dword [esi + 8]
mov dword [edi], eax
mov eax, dword [edi + 0x10]
mov dword [edi + 0x14], eax
xor eax, eax
push eax
lea ecx, [edi - 0x18]
push ecx
mov dword [ecx], eax
mov dword [ecx + 4], eax
push dword [edi]
push dword [edi + 0x14]
push ebx
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x401985
mov eax, dword [edi - 0x18]
add dword [edi + 0x14], eax
sub dword [edi], eax
jne 0x4018ec
mov eax, dword [esi + 8]
mov dword [edi], eax
mov eax, dword [edi + 0x10]
mov dword [edi + 0x14], eax
xor eax, eax
push eax
lea ecx, [edi - 0x18]
push ecx
mov dword [ecx], eax
mov dword [ecx + 4], eax
push dword [edi]
push dword [edi + 0x14]
push ebp
call dword [sym.imp.KERNEL32.DLL_WriteFile]
test eax, eax
je 0x401985
mov eax, dword [edi - 0x18]
add dword [edi + 0x14], eax
sub dword [edi], eax
jne 0x40191d
dec dword [edi + 4]
jne 0x4018e1
xor eax, eax
push eax
push eax
push eax
push ebx
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
dec dword [edi + 8]
jne 0x4018db
lea eax, [edi - 8]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemTimeAsFileTime]
mov eax, dword [edi - 8]
mov edx, dword [edi - 4]
sub eax, dword [edi - 0x10]
sbb edx, dword [edi - 0xc]
mov dword [edi - 0x28], eax
mov dword [edi - 0x24], edx
push ebx
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
test eax, eax
je 0x40199a
lea eax, [esi + 0x30]
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileA]
push ebp
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
test eax, eax
je 0x4019b5
lea eax, [esi + 0x400]
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileA]
mov dword [edi - 0x20], eax
pop ebp
pop edi
pop esi
pop ebx
ret