Function at 0x41a568
Capabilities:
Check if file exists
Delete file
Write file on windows

Disassembly:
mov eax, 0x42ceab
call fcn.00421904
mov eax, 0x2ac8
call fcn.00420a50
push ebx
mov ebx, ecx
push esi
push edi
lea ecx, [ebp - 0x2ad4]
call fcn.0041dbe0
xor edi, edi
lea ecx, [ebp - 0x2ad4]
mov dword [ebp - 4], edi
call fcn.0041f7ad
push eax
lea eax, [ebp - 0x114]
push eax
call fcn.00420680
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x114]
push dword [esi + 0x10]
push eax
call fcn.00420690
mov eax, dword [esi + 8]
add esp, 0x10
sub eax, edi
je 0x41a6dd
dec eax
je 0x41a686
dec eax
je 0x41a5da
push 4
jmp 0x41a724
push edi
push 0x80
push 4
push edi
push 1
lea eax, [ebp - 0x114]
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp + 8], eax
jne 0x41a61e
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x41a61b
lea eax, [ebp - 0x114]
push eax
push str.Append_file___s__pending.
jmp 0x41a719
push eax
jmp 0x41a653
push 2
push edi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea eax, [ebp - 0x10]
push edi
push eax
push dword [esi + 0x1c]
push dword [esi + 0x14]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x41a66f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp + 8]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
lea eax, [ebp - 0x114]
push eax
push str.Append_file___s__fail._GetLastError___d
push ebx
call fcn.004227b3
add esp, 0x10
push 8
jmp 0x41a724
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x114]
push eax
push str.Append_file___s__success.
jmp 0x41a6cf
lea eax, [ebp - 0x114]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x41a6c3
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
jne 0x41a6b0
lea eax, [ebp - 0x114]
push eax
push str.Del_file___s__fail._File_Not_Found.
jmp 0x41a6cf
cmp eax, 5
jne 0x41a6c3
lea eax, [ebp - 0x114]
push eax
push str.Del_file___s__pending.
jmp 0x41a719
lea eax, [ebp - 0x114]
push eax
push str.Del_file___s__success.
push ebx
call fcn.004227b3
add esp, 0xc
jmp 0x41a781
push edi
push 0x80
push 2
push edi
push 1
lea eax, [ebp - 0x114]
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp + 8], eax
jne 0x41a739
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x41a727
lea eax, [ebp - 0x114]
push eax
push str.Add_file___s__pending.
push ebx
call fcn.004227b3
add esp, 0xc
push 9
pop esi
jmp 0x41a783
push eax
lea eax, [ebp - 0x114]
push eax
push str.Add_file___s__fail._GetLastError___d
jmp 0x41a65f
lea ecx, [ebp - 0x10]
push edi
push ecx
push dword [esi + 0x1c]
push dword [esi + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x41a763
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp + 8]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
jmp 0x41a728
lea eax, [ebp - 0x114]
push eax
push str.Add_file___s__success.
push ebx
call fcn.004227b3
add esp, 0xc
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor esi, esi
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2ad4]
call fcn.0041dcb8
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 4