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

Disassembly:
push 0xffffffffffffffff
mov eax, dword fs:[0]
push 0x4075cb
push eax
mov eax, 0x1d24
mov dword fs:[0], esp
call fcn.00406e80
push ebx
push ebp
mov ebp, ecx
push esi
push edi
mov eax, dword [ebp + 0x7c]
mov ecx, dword [eax - 8]
mov dl, byte [eax + ecx - 1]
cmp dl, 0x5c
je 0x404659
cmp dl, 0x2f
je 0x404659
push eax
lea ecx, [esp + 0x41c]
push 0x40bbfc
push ecx
jmp 0x40466a
mov edx, dword [ebp + 0x7c]
lea eax, [esp + 0x418]
push edx
push 0x40b3c4
push eax
mov ebx, dword [sym.imp.MSVCRT.dll_sprintf]
call ebx
lea edi, [esp + 0x424]
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 3
jbe 0x4046e7
lea ecx, [esp + 0x418]
push ecx
call fcn.004022d0
add esp, 4
test eax, eax
jne 0x4046e7
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea edx, [esp + 0x418]
push eax
push edx
lea eax, [esp + 0x20]
push 0x40bbdc
push eax
call ebx
add esp, 0x10
lea ecx, [esp + 0x18]
push ecx
lea ecx, [ebp + 0x80]
call fcn.00402930
push 0
lea edx, [esp + 0x1c]
push 0x40b398
push edx
mov ecx, ebp
call sub.MFC42.DLL_CWnd::MessageBoxA
xor eax, eax
jmp 0x4048f7
lea eax, [esp + 0x10]
push eax
push 0x40bbd8
push 0x89
push 0
call fcn.004023a0
mov dword [esp + 0x24], eax
lea edi, [esp + 0x428]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
lea edx, [esp + 0x818]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov byte [esp + 0x818], 0
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x818]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
mov edi, str.setup.tmp
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x80
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 2
mov ecx, edx
push eax
push eax
and ecx, 3
lea eax, [esp + 0x82c]
push 0xc0000000
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
or edi, 0xffffffff
cmp esi, edi
jne 0x4047d6
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [esp + 0x418]
push eax
push ecx
lea edx, [esp + 0x20]
push 0x40bbac
push edx
call ebx
add esp, 0x10
lea eax, [esp + 0x18]
lea ecx, [ebp + 0x80]
push eax
call fcn.00402930
push 0
lea ecx, [esp + 0x1c]
push 0x40b398
push ecx
mov ecx, ebp
call sub.MFC42.DLL_CWnd::MessageBoxA
xor eax, eax
jmp 0x4048f7
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
lea edx, [esp + 0x10]
push 0
push edx
push eax
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x404832
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [esp + 0x1c]
push 0x40bb94
push edx
call ebx
add esp, 0xc
lea eax, [esp + 0x18]
lea ecx, [ebp + 0x80]
push eax
call fcn.00402930
push 0
lea ecx, [esp + 0x1c]
push 0x40b398
push ecx
mov ecx, ebp
call sub.MFC42.DLL_CWnd::MessageBoxA
xor eax, eax
jmp 0x4048f7
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x112c]
call fcn.00402980
mov edx, dword [esp + 0x1d44]
lea eax, [esp + 0x418]
push edx
lea ecx, [esp + 0x81c]
push eax
push ecx
lea ecx, [esp + 0x1138]
mov dword [esp + 0x1d48], 0
call fcn.004029f0
test eax, eax
je 0x4048d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [esp + 0xd30]
push 0x40ba30
push edx
call ebx
add esp, 0xc
lea eax, [esp + 0xd2c]
lea ecx, [ebp + 0x80]
push eax
call fcn.00402930
push 0
lea ecx, [esp + 0xd30]
push 0x40b398
push ecx
mov ecx, ebp
call sub.MFC42.DLL_CWnd::MessageBoxA
lea ecx, [esp + 0x112c]
mov dword [esp + 0x1d3c], edi
call fcn.004029e0
xor eax, eax
jmp 0x4048f7
lea edx, [esp + 0x818]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0x112c]
mov dword [esp + 0x1d3c], edi
call fcn.004029e0
mov eax, 1
mov ecx, dword [esp + 0x1d34]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x1d30
ret 4