Function at 0x503600
Capabilities:
Check if file exists
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5fa908
mov eax, dword fs:[0]
push eax
sub esp, 0x68
mov eax, dword [0x67d070]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, edx
mov esi, ecx
push 0xffffffffffffffff
push 0
push esi
lea ecx, [ebp - 0x5c]
mov dword [ebp - 0x48], 0xf
mov dword [ebp - 0x4c], 0
mov byte [ebp - 0x5c], 0
call fcn.00407300
mov dword [ebp - 4], 0
xor eax, eax
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], ax
mov dword [ebp - 0x30], 7
mov dword [ebp - 0x34], eax
mov word [ebp - 0x44], ax
lea edx, [ebp - 0x2c]
mov byte [ebp - 4], 2
mov ecx, esi
call fcn.00502a30
test al, al
jne 0x5036a8
call fcn.00572740
push str.Failed_to_get_wide_string_path
push 0x647e5c
push eax
mov ecx, dword [eax]
call dword [ecx + 0x44]
add esp, 0xc
xor bl, bl
jmp 0x503853
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x5036fc
call fcn.00572740
cmp dword [ebp - 0x18], 8
lea edx, [ebp - 0x2c]
cmovae edx, dword [ebp - 0x2c]
mov ecx, dword [eax]
push edx
push str.File__s_does_not_exist
push 0x647e5c
push eax
call dword [ecx + 0x44]
add esp, 0x10
push str.File_does_not_exists_to_create_backup
push 0x647e5c
call fcn.00572740
push eax
call fcn.005734e0
jmp 0x50384e
lea ecx, [ebp - 0x5c]
call fcn.005038e0
test al, al
jne 0x503727
call fcn.00572740
push str.Failed_to_remove_discriminator_from_the_end_of_file
push 0x647e5c
push eax
mov ecx, dword [eax]
call dword [ecx + 0x54]
add esp, 0xc
xor bl, bl
jmp 0x503853
push str._bkp
lea edx, [ebp - 0x5c]
lea ecx, [ebp - 0x74]
call fcn.004521e0
add esp, 4
mov ecx, edi
push eax
call fcn.00408150
lea ecx, [ebp - 0x74]
call fcn.00406ec0
lea edx, [ebp - 0x44]
mov ecx, edi
call fcn.00502a30
test al, al
jne 0x503777
call fcn.00572740
push str.Failed_to_get_wide_string_backup_file_path
push 0x647e5c
push eax
mov ecx, dword [eax]
call dword [ecx + 0x44]
add esp, 0xc
xor bl, bl
jmp 0x503853
mov dl, 1
lea ecx, [ebp - 0x44]
call fcn.00502c80
test al, al
jne 0x5037af
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push eax
push str.Failed_to_remove_the_backup_file_already_present:_d
push 0x647e5c
push ecx
call fcn.00572740
add esp, 4
push eax
call fcn.00573570
add esp, 0x10
xor bl, bl
jmp 0x503853
cmp dword [ebp - 0x30], 8
lea ecx, [ebp - 0x44]
mov edi, dword [sym.imp.KERNEL32.DLL_MoveFileExW]
lea eax, [ebp - 0x2c]
cmovae ecx, dword [ebp - 0x44]
cmp dword [ebp - 0x18], 8
push 8
cmovae eax, dword [ebp - 0x2c]
push ecx
push eax
call edi
test eax, eax
jne 0x503839
mov esi, dword [sym.imp.KERNEL32.DLL_GetLastError]
call esi
cmp eax, 5
jne 0x503816
cmp dword [ebp - 0x18], 8
lea ecx, [ebp - 0x2c]
cmovae ecx, dword [ebp - 0x2c]
call fcn.00503330
test al, al
je 0x503816
cmp dword [ebp - 0x30], 8
lea ecx, [ebp - 0x44]
push 8
cmovae ecx, dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
cmp dword [ebp - 0x18], 8
push ecx
cmovae eax, dword [ebp - 0x2c]
push eax
call edi
test eax, eax
jne 0x503839
call esi
push eax
push str.Failed_to_create_Backup_file_:_d
push 0x647e5c
push ecx
call fcn.00572740
add esp, 4
push eax
call fcn.00573570
add esp, 0x10
xor bl, bl
jmp 0x503853
call fcn.00572740
push str.Backup_file_Created
push 0x647e5c
push eax
mov ecx, dword [eax]
call dword [ecx + 0x54]
mov bl, 1
add esp, 0xc
mov eax, dword [ebp - 0x30]
cmp eax, 8
jb 0x503868
inc eax
lea ecx, [ebp - 0x44]
push eax
push dword [ebp - 0x44]
call fcn.00407b40
xor eax, eax
mov dword [ebp - 0x30], 7
mov word [ebp - 0x44], ax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x34], 0
cmp eax, 8
jb 0x503891
inc eax
lea ecx, [ebp - 0x2c]
push eax
push dword [ebp - 0x2c]
call fcn.00407b40
mov ecx, dword [ebp - 0x48]
xor eax, eax
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], ax
cmp ecx, 0x10
jb 0x5038ba
inc ecx
push ecx
push dword [ebp - 0x5c]
lea ecx, [ebp - 0x5c]
call fcn.00407440
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00599c70
mov esp, ebp
pop ebp
ret