Function at 0x4012d0
Capabilities:
Delete file
Get file size
Read file on windows
Timestomp file
Write file on windows

Disassembly:
sub esp, 0x320
push ebx
push ebp
mov ebp, dword [esp + 0x32c]
push esi
push edi
xor ebx, ebx
xor edi, edi
cmp ebp, ebx
mov dword [esp + 0x14], ecx
je 0x401803
mov esi, dword [esp + 0x33c]
cmp esi, ebx
je 0x401803
call fcn.00401180
test eax, eax
je 0x401803
cmp dword [ebp + 0x104], 1
jne 0x401803
push 0x4000
call fcn.00401ec9
mov ebp, eax
add esp, 4
cmp ebp, ebx
je 0x401803
mov eax, dword [esp + 0x338]
mov ecx, 0x40
inc eax
lea edi, [esp + 0x25]
mov dword [ebp + 4], eax
xor eax, eax
mov byte [esp + 0x24], bl
mov dword [ebp], 2
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x24]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp byte [esp + ecx + 0x23], 0x5c
je 0x4013bd
mov edi, 0x409040
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x334]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
push 0x80
mov ecx, edx
push 3
push ebx
and ecx, 3
push 3
lea eax, [esp + 0x38]
push 0xc0000000
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x401525
mov edi, dword [sym.imp.KERNEL32.dll_GetFileSize]
lea ecx, [esp + 0x10]
push ecx
push esi
mov dword [esp + 0x18], ebx
call edi
lea edx, [esp + 0x10]
mov dword [ebp + 8], eax
push edx
push esi
call edi
mov dword [ebp + 0xc], eax
lea eax, [ebp + 0x10]
push eax
push ebx
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileTime]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x129]
mov byte [esp + 0x128], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x128]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x12c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push 0x80
rep movsb byte es:[edi], byte [esi]
mov edi, str..bsu
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 3
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push ebx
and ecx, 3
push 3
lea eax, [esp + 0x13c]
push 0xc0000000
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x401531
lea ecx, [esp + 0x10]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xc
mov dword [esp + 0x10], eax
jb 0x401510
lea edx, [esp + 0x10]
push ebx
push edx
lea eax, [ebp + 0xc]
push 0xc
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x401531
push esi
mov dword [ebp + 8], ebx
mov dword [ebp + 0xc], ebx
mov dword [ebp + 0x10], ebx
mov dword [ebp + 0x14], ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x401531
mov dword [ebp + 8], ebx
mov dword [ebp + 0xc], ebx
mov dword [ebp + 0x10], ebx
mov dword [ebp + 0x14], ebx
mov edi, dword [esp + 0x334]
or ecx, 0xffffffff
xor eax, eax
lea edx, [ebp + 0x18]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x400
mov eax, ecx
mov esi, edi
mov edi, edx
push ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x1c]
mov ecx, dword [esi]
push ecx
call fcn.00401870
mov edx, dword [esi]
push 0x400
push ebp
push edx
call fcn.00401820
mov eax, dword [ebp]
add esp, 0x18
cmp eax, ebx
mov dword [esp + 0x20], eax
jbe 0x4017f4
mov eax, dword [ebp + 4]
push ebx
neg eax
sbb eax, eax
push 0x80
and eax, 2
add eax, 2
push eax
push ebx
push 3
lea eax, [esp + 0x38]
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
je 0x4017f4
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x22d]
mov byte [esp + 0x22c], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x22c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x230]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push 0x80
rep movsb byte es:[edi], byte [esi]
mov edi, str..bsu
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 4
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push ebx
and ecx, 3
push 3
lea eax, [esp + 0x240]
push 0xc0000000
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
mov esi, eax
cmp esi, 0xffffffff
je 0x401685
lea ecx, [esp + 0x18]
push ebx
push ecx
lea eax, [ebp + 8]
push 4
push eax
push esi
mov dword [esp + 0x2c], ebx
call edi
lea edx, [esp + 0x18]
push ebx
push edx
lea eax, [ebp + 0xc]
push 8
push eax
push esi
call edi
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
push 2
push ebx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x20]
xor esi, esi
cmp eax, ebx
jbe 0x4016e1
mov ecx, dword [esp + 0x14]
push 0x1000
push ebp
mov edx, dword [ecx]
push edx
call fcn.00401820
add esp, 0xc
cmp eax, 0x1000
jne 0x4016e1
cmp dword [ebp], esi
jne 0x4016e1
mov ecx, dword [ebp + 4]
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x18]
push ebx
push eax
lea eax, [ebp + 8]
push ecx
push eax
push edx
mov dword [esp + 0x2c], ebx
call edi
mov eax, dword [esp + 0x20]
inc esi
cmp esi, eax
jb 0x40169e
cmp esi, dword [esp + 0x20]
jne 0x4017d5
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x129]
mov byte [esp + 0x128], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x128]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x12c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push 0x80
rep movsb byte es:[edi], byte [esi]
mov edi, str..bsu
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 3
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
push ebx
and ecx, 3
push 3
lea eax, [esp + 0x13c]
push 0xc0000000
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x4017c7
push ebx
push ebx
push 4
push esi
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea ecx, [esp + 0x14]
push ebx
push ecx
lea edx, [esp + 0x20]
push 8
push edx
push esi
mov dword [esp + 0x28], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x18]
push eax
push ebx
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edx, [esp + 0x128]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [esp + 0x10]
mov esi, 1
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x320
ret 0xc
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x320
ret 0xc
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x320
ret 0xc