Function at 0x478920
Capabilities:
Copy file
Get common file path
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4841e0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x50c
push ebx
push esi
push edi
lea eax, [ebp - 0x118]
mov dword [ebp - 0x10], esp
push 0x80
push eax
mov dword [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov ebx, dword [ebp + 8]
push 0x492024
push ebx
call fcn.0047bec0
add esp, 8
test eax, eax
je 0x478a4a
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
lea edx, [ebp - 0x418]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [ebp - 0x418]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp eax, ecx
jge 0x4789ce
mov edx, ecx
sub edx, eax
mov dl, byte [ebp + edx - 0x418]
cmp dl, 0x5c
mov byte [ebp + eax - 0x98], dl
jne 0x4789cb
cmp eax, 2
jge 0x4789ce
inc eax
jmp 0x4789ab
sub ecx, eax
xor edx, edx
mov esi, ecx
cmp edx, eax
jge 0x4789fb
lea ecx, [edx + esi]
mov cl, byte [ebp + ecx - 0x417]
cmp cl, 0x5c
je 0x4789f0
mov byte [ebp + edx - 0x98], cl
jne 0x4789f8
mov byte [ebp + edx - 0x98], 0
inc edx
jmp 0x4789d4
mov byte [ebp + eax - 0x98], 0
lea edx, [ebp - 0x98]
lea eax, [ebp - 0x118]
push edx
push eax
lea ecx, [ebp - 0x218]
push 0x4966e0
push ecx
call fcn.0047a8f8
lea edx, [ebp - 0x98]
lea eax, [ebp - 0x118]
push edx
push eax
lea ecx, [ebp - 0x318]
push str._sdllcache_bk_s
push ecx
call fcn.0047a8f8
lea edx, [ebp - 0x98]
push edx
jmp 0x478a7d
lea edx, [ebp - 0x118]
push ebx
push edx
lea eax, [ebp - 0x218]
push 0x4966e0
push eax
call fcn.0047a8f8
lea ecx, [ebp - 0x118]
push ebx
push ecx
lea edx, [ebp - 0x318]
push str._sdllcache_bk_s
push edx
call fcn.0047a8f8
push ebx
lea eax, [ebp - 0x118]
lea ecx, [ebp - 0x518]
push eax
push str._sdllcache_s
push ecx
call fcn.0047a8f8
add esp, 0x30
xor edi, edi
xor esi, esi
push str.c:endpcache
call fcn.0047c0d3
lea edx, [ebp - 0x218]
push edx
call fcn.00428d90
add esp, 8
push 0x491c80
push eax
call fcn.0047fde0
add esp, 8
test eax, eax
jne 0x478acc
mov edi, 1
lea eax, [ebp - 0x318]
push eax
call fcn.00428d90
add esp, 4
push 0x491c80
push eax
call fcn.0047fde0
add esp, 8
test eax, eax
jne 0x478af2
mov esi, 1
cmp edi, 1
jne 0x478b50
test esi, esi
jne 0x478ce4
push ebx
lea ecx, [ebp - 0x98]
push str.c:endpcachelog_s
push ecx
call fcn.0047a8f8
add esp, 0xc
lea edx, [ebp - 0x98]
lea eax, [ebp - 0x318]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileA]
lea ecx, [ebp - 0x318]
push esi
lea edx, [ebp - 0x218]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp esi, 1
jne 0x478be9
push ebx
lea eax, [ebp - 0x98]
push str.c:endpcachelog_s
push eax
call fcn.0047a8f8
mov esi, dword [sym.imp.KERNEL32.dll_MoveFileA]
add esp, 0xc
lea ecx, [ebp - 0x98]
lea edx, [ebp - 0x218]
push ecx
push edx
call esi
mov edi, dword [sym.imp.KERNEL32.dll_CopyFileA]
lea eax, [ebp - 0x218]
push 0
lea ecx, [ebp - 0x318]
push eax
push ecx
call edi
push ebx
lea edx, [ebp - 0x98]
push str.c:endpcachelog_s
push edx
call fcn.0047a8f8
add esp, 0xc
lea eax, [ebp - 0x98]
lea ecx, [ebp - 0x218]
push eax
push ecx
call esi
lea edx, [ebp - 0x218]
push 0
lea eax, [ebp - 0x318]
push edx
push eax
call edi
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, dword [sym.imp.imagehlp.dll_MapFileAndCheckSumA]
lea ecx, [ebp - 0x14]
lea edx, [ebp - 0x18]
push ecx
lea eax, [ebp - 0x218]
xor edi, edi
push edx
push eax
mov dword [ebp - 0x18], 1
mov dword [ebp - 0x14], edi
call ebx
test eax, eax
jne 0x478c1a
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x14]
cmp ecx, eax
je 0x478c1f
mov edi, 1
lea edx, [ebp - 0x14]
lea eax, [ebp - 0x18]
push edx
lea ecx, [ebp - 0x318]
push eax
push ecx
xor esi, esi
call ebx
test eax, eax
jne 0x478c40
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x14]
cmp edx, eax
je 0x478c45
mov esi, 1
cmp edi, 1
jne 0x478ca2
test esi, esi
jne 0x478ca2
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x98]
push eax
push str.c:endpcachelog_s
push ecx
call fcn.0047a8f8
add esp, 0xc
lea edx, [ebp - 0x98]
lea eax, [ebp - 0x218]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileA]
lea ecx, [ebp - 0x218]
push esi
lea edx, [ebp - 0x318]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x98]
push eax
push str.c:endpcachelog_s
push ecx
call fcn.0047a8f8
add esp, 0xc
lea edx, [ebp - 0x98]
lea eax, [ebp - 0x218]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileA]
lea ecx, [ebp - 0x218]
push 0
lea edx, [ebp - 0x518]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret