Function at 0x410257
Capabilities:
Check if file exists
Copy file
Create directory
Delete file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34c
push edi
mov dword [ebp - 0x138], 0
mov dword [ebp - 0x114], 0
mov dword [ebp - 0x130], 0
mov dword [ebp - 0x128], 0
mov dword [ebp - 0x134], 0
mov byte [ebp - 0x108], 0
mov ecx, 0x40
xor eax, eax
lea edi, [ebp - 0x107]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov dword [ebp - 4], str.Logsupdate.log
mov dword [ebp - 0x10c], str.Logs_backupupdate_s.log
mov dword [ebp - 0x110], 0x20
mov dword [ebp - 0x12c], 0xfde8
cmp dword [0x4397a0], 0
je 0x4102df
jmp 0x4106a2
mov eax, dword [ebp + 8]
push eax
call sub.MSVCRT.dll_strlen
add esp, 4
add eax, 0x20
mov dword [ebp - 0x130], eax
mov ecx, dword [ebp - 0x130]
push ecx
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [ebp - 0x348], eax
mov edx, dword [ebp - 0x348]
mov dword [ebp - 0x128], edx
cmp dword [ebp - 0x128], 0
jne 0x410323
jmp 0x4106a0
lea eax, [ebp - 0x124]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
cmp dword [0x4397c0], 0
jne 0x410573
push 0x104
push 0x4398d0
call fcn.0040ea68
add esp, 8
push str.Logs
push 0x4398d0
call sub.MSVCRT.dll_strcat
add esp, 8
push 0x4398d0
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x41037d
push 0
push 0x4398d0
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push str._backup
push 0x4398d0
call sub.MSVCRT.dll_strcat
add esp, 8
push 0x4398d0
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x4103ab
push 0
push 0x4398d0
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push 0x104
push 0x4397cc
call fcn.0040ea68
add esp, 8
mov ecx, dword [ebp - 4]
push ecx
push 0x4397cc
call sub.MSVCRT.dll_strcat
add esp, 8
push 0x4339ec
push 0x4397cc
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x134], eax
cmp dword [ebp - 0x134], 0
je 0x410546
push 2
push 0
mov edx, dword [ebp - 0x134]
push edx
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
mov dword [ebp - 0x114], eax
cmp dword [ebp - 0x114], 0
jne 0x410546
mov dword [ebp - 0x13c], 0
mov eax, dword [ebp - 0x134]
push eax
call dword [sym.imp.MSVCRT.dll_ftell]
add esp, 4
mov dword [ebp - 0x13c], eax
cmp dword [ebp - 0x13c], 0xfde8
jbe 0x410546
mov byte [ebp - 0x344], 0
mov ecx, 0x40
xor eax, eax
lea edi, [ebp - 0x343]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov byte [ebp - 0x240], 0
mov ecx, 0x40
xor eax, eax
lea edi, [ebp - 0x23f]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, dword [ebp - 0x134]
push ecx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
mov dword [ebp - 0x134], 0
mov edx, dword [ebp - 0x11a]
and edx, 0xffff
push edx
mov eax, dword [ebp - 0x11c]
and eax, 0xffff
push eax
mov ecx, dword [ebp - 0x11e]
and ecx, 0xffff
push ecx
mov edx, dword [ebp - 0x122]
and edx, 0xffff
push edx
push str._02d_02d_02d_02d
lea eax, [ebp - 0x344]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x18
lea ecx, [ebp - 0x344]
push ecx
mov edx, dword [ebp - 0x10c]
push edx
lea eax, [ebp - 0x240]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
push 0x104
lea ecx, [ebp - 0x108]
push ecx
call fcn.0040ea68
add esp, 8
lea edx, [ebp - 0x240]
push edx
lea eax, [ebp - 0x108]
push eax
call sub.MSVCRT.dll_strcat
add esp, 8
push 0
lea ecx, [ebp - 0x108]
push ecx
push 0x4397cc
call dword [sym.imp.KERNEL32.dll_CopyFileA]
push 0x4397cc
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
cmp dword [ebp - 0x134], 0
je 0x410569
mov edx, dword [ebp - 0x134]
push edx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
mov dword [ebp - 0x134], 0
mov dword [0x4397c0], 1
push 0x433a04
push 0x4397cc
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x134], eax
cmp dword [ebp - 0x134], 0
jne 0x41059a
jmp 0x41069e
push 4
push 0
mov eax, dword [ebp - 0x128]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
mov ecx, dword [ebp + 8]
push ecx
mov edx, dword [ebp - 0x118]
and edx, 0xffff
push edx
mov eax, dword [ebp - 0x11a]
and eax, 0xffff
push eax
mov ecx, dword [ebp - 0x11c]
and ecx, 0xffff
push ecx
mov edx, dword [ebp - 0x11e]
and edx, 0xffff
push edx
mov eax, dword [ebp - 0x122]
and eax, 0xffff
push eax
mov ecx, dword [ebp - 0x124]
and ecx, 0xffff
push ecx
push str._04d__02d__02d__02d:_02d:_02d__s_n
mov edx, dword [ebp - 0x128]
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x24
push 2
push 0
mov eax, dword [ebp - 0x134]
push eax
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
mov ecx, dword [ebp - 0x134]
push ecx
mov edx, dword [ebp - 0x128]
push edx
call sub.MSVCRT.dll_strlen
add esp, 4
push eax
push 1
mov eax, dword [ebp - 0x128]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov dword [ebp - 0x138], 1
cmp dword [ebp - 0x134], 0
je 0x410672
mov ecx, dword [ebp - 0x134]
push ecx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
cmp dword [ebp - 0x128], 0
je 0x410696
mov edx, dword [ebp - 0x128]
mov dword [ebp - 0x34c], edx
mov eax, dword [ebp - 0x34c]
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov eax, dword [ebp - 0x138]
jmp 0x4106a4
jmp 0x410659
jmp 0x410659
jmp 0x41064f
pop edi
mov esp, ebp
pop ebp
ret