Function at 0x1017810
Capabilities:
Delete file
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x430
mov eax, dword [0x1035030]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov dword [ebp - 0x430], eax
xor eax, eax
mov edi, 0x206
push edi
mov word [ebp - 0x20c], ax
xor ebx, ebx
lea eax, [ebp - 0x20a]
push ebx
push eax
mov esi, ecx
call sub.msvcrt.dll_memset
xor eax, eax
push edi
mov word [ebp - 0x414], ax
lea eax, [ebp - 0x412]
push ebx
push eax
call sub.msvcrt.dll_memset
xor eax, eax
mov word [ebp - 0x42c], ax
lea edi, [ebp - 0x42a]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
add esp, 0x18
or edi, 0xffffffff
mov dword [ebp - 0x418], ebx
mov dword [ebp - 0x41c], ebx
cmp dword [esi + 0x68], ebx
je 0x1017aa6
cmp dword [esi + 0x28], ebx
je 0x1017aa6
cmp dword [esi + 8], ebx
je 0x1017aa6
cmp dword [esi + 0xc], 0x78
jb 0x1017aa6
lea eax, [ebp - 0x42c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
mov eax, dword [esi + 0x28]
push dword [eax]
mov edi, 0x104
push edi
lea eax, [ebp - 0x414]
push eax
call fcn.010069ac
cmp eax, ebx
jge 0x101790f
mov ecx, dword [0x1035014]
cmp ecx, 0x1035014
je 0x1017ade
test byte [ecx + 0x1c], 2
je 0x1017ade
push eax
push 0x1003a20
push 0x7f
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01004eb4
jmp 0x1017ade
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
cmp eax, ebx
jne 0x1017954
mov eax, dword [0x1035014]
cmp eax, 0x1035014
je 0x1017ade
test byte [eax + 0x1c], 2
je 0x1017ade
push 0x1003a20
push 0x80
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01004e8e
jmp 0x1017ade
push dword [ebp + 0xc]
movzx ecx, word [ebp - 0x41e]
push ecx
movzx ecx, word [ebp - 0x420]
push ecx
movzx ecx, word [ebp - 0x422]
push ecx
movzx ecx, word [ebp - 0x424]
push ecx
movzx ecx, word [ebp - 0x426]
push ecx
movzx ecx, word [ebp - 0x42a]
push ecx
movzx ecx, word [ebp - 0x42c]
push ecx
push eax
push dword [ebp - 0x430]
lea eax, [ebp - 0x20c]
push dword [esi + 0x68]
push 0x1003b48
push edi
push eax
call fcn.01006a35
add esp, 0x38
cmp eax, ebx
jge 0x10179de
mov ecx, dword [0x1035014]
cmp ecx, 0x1035014
je 0x1017ade
test byte [ecx + 0x1c], 2
je 0x1017ade
push eax
push 0x1003a20
push 0x81
jmp 0x10178ff
push ebx
push 0x80
push 1
push ebx
push ebx
push 0xc0000000
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
jne 0x1017a41
mov eax, dword [0x1035014]
cmp eax, 0x1035014
je 0x1017ade
test byte [eax + 0x1c], 2
je 0x1017ade
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [0x1035014]
push 0x1003a20
push 0x82
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01004eb4
jmp 0x1017ade
push ebx
lea eax, [ebp - 0x418]
push eax
push dword [esi + 0xc]
push dword [esi + 8]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1017a71
mov eax, dword [ebp - 0x418]
cmp eax, dword [esi + 0xc]
jne 0x1017a71
mov dword [ebp - 0x41c], 1
jmp 0x1017aca
mov eax, dword [0x1035014]
cmp eax, 0x1035014
je 0x1017aca
test byte [eax + 0x1c], 2
je 0x1017aca
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [0x1035014]
push 0x1003a20
push 0x83
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01004eb4
jmp 0x1017aca
mov eax, dword [0x1035014]
cmp eax, 0x1035014
je 0x1017ade
test byte [eax + 0x1c], 2
je 0x1017ade
push 0x1003a20
push 0x7e
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01004e8e
cmp edi, 0xffffffff
je 0x1017ad6
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x41c], ebx
jne 0x1017aeb
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.01011f27
leave
ret 8