Function at 0x523a5f06
Capabilities:
Copy file
Delete file
Move file

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x32c
mov eax, dword [0x523ac650]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov esi, ecx
mov edi, 0x105
push edi
lea ecx, [ebp - 0x214]
push ecx
push edi
lea ecx, [ebp - 0x31c]
push ecx
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push eax
call sub.msvcrt.dll__splitpath_s
add esp, 0x24
lea eax, [esi + 0x158]
push eax
mov dword [ebp - 0x32c], eax
push edi
lea eax, [ebp - 0x10c]
push eax
call fcn.5238953f
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp eax, ebx
je 0x523a5f7c
cmp byte [ebp + eax - 0x10d], 0x5c
je 0x523a5fa4
lea eax, [ebp - 0x10c]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x523a5f85
sub eax, edx
push 0x52382dd0
mov ecx, edi
sub ecx, eax
push ecx
lea eax, [ebp - 0x10c]
push eax
call fcn.523895ad
lea eax, [ebp - 0x10c]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x523a5fad
lea ecx, [ebp - 0x31c]
push ecx
sub eax, edx
mov ecx, edi
sub ecx, eax
push ecx
lea eax, [ebp - 0x10c]
push eax
call fcn.523895ad
lea eax, [ebp - 0x10c]
lea ecx, [eax + 1]
mov dl, byte [eax]
inc eax
cmp dl, bl
jne 0x523a5fd7
sub eax, ecx
lea ecx, [ebp - 0x214]
push ecx
sub edi, eax
push edi
lea eax, [ebp - 0x10c]
push eax
call fcn.523895ad
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 4], ebx
mov dword [esi + 0xc], ebx
mov dword [esi + 8], ebx
mov dword [esi + 0x10], ebx
mov dword [esi + 0x14], ebx
cmp dword [0x523adfbc], 3
je 0x523a603b
xor eax, eax
cmp dword [ebp + 0xc], ebx
lea edi, [esi + 0x54]
setne al
mov dword [ebp - 0x328], edi
inc eax
inc eax
push eax
lea eax, [ebp - 0x10c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
jmp 0x523a607f
cmp dword [ebp + 0xc], ebx
je 0x523a6062
lea eax, [ebp - 0x10c]
push eax
lea eax, [esi + 0x54]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x523a6062
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [ebp - 0x10c]
lea eax, [esi + 0x54]
push ecx
push eax
mov dword [ebp - 0x328], eax
call dword [sym.imp.KERNEL32.dll_MoveFileA]
mov edi, dword [ebp - 0x328]
mov dword [ebp - 0x320], eax
cmp eax, ebx
jne 0x523a60c6
xor eax, eax
cmp dword [ebp + 0xc], ebx
sete al
push eax
lea eax, [ebp - 0x10c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CopyFileA]
push edi
mov dword [ebp - 0x324], eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
cmp dword [ebp - 0x324], ebx
jne 0x523a60cc
push ebx
push ebx
push 1
push 0xe0000005
call dword [sym.imp.KERNEL32.dll_RaiseException]
lea edi, [ebp - 0x10c]
push 1
push edi
call fcn.523a5d4a
mov edi, eax
cmp edi, ebx
jne 0x523a60e9
push ebx
push ebx
push 1
push 0xe0000003
call dword [sym.imp.KERNEL32.dll_RaiseException]
mov eax, dword [edi + 8]
mov dword [ebp - 0x324], eax
mov dword [esi + 8], eax
cmp dword [ebp - 0x320], ebx
je 0x523a612a
mov eax, dword [ebp + 0x10]
cmp eax, ebx
jl 0x523a612a
mov ecx, dword [edi + 0x10]
lea eax, [ecx + eax - 1]
xor edx, edx
div ecx
push ebx
push ebx
imul eax, ecx
push eax
push dword [ebp - 0x324]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
xor eax, eax
cmp dword [ebp - 0x320], ebx
mov dword [esi + 4], 1
sete al
mov dword [esi + 0xc], eax
mov eax, dword [edi + 0x10]
mov dword [esi + 0x10], eax
mov eax, dword [edi + 0x14]
mov dword [esi + 0x14], eax
lea eax, [edi + 0x54]
push eax
mov esi, 0x104
push esi
push dword [ebp - 0x328]
call fcn.5238953f
lea eax, [edi + 0x158]
push eax
push esi
push dword [ebp - 0x32c]
call fcn.5238953f
push 1
mov ecx, edi
mov dword [edi + 4], ebx
call fcn.52395933
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.523a8462
leave
ret 0xc