Function at 0x478010
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50d548
mov eax, dword fs:[0]
push eax
sub esp, 0x24
push ebx
push esi
push edi
mov eax, dword [0x572bb0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, edx
mov edi, ecx
call fcn.00477880
test al, al
jne 0x4781ca
push str.file_not_exists:
lea ecx, [ebp - 0x20]
call fcn.00471c70
push str.CopyFile
lea ecx, [ebp - 0x1c]
mov dword [ebp - 4], 0
call fcn.00471bb0
mov byte [ebp - 4], 1
call fcn.00460220
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x47808a
push 0x80004005
call fcn.004712d0
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
mov byte [ebp - 4], 2
push eax
lea edx, [ebp - 0x18]
lea ecx, [ebp - 0x28]
call fcn.00472fc0
push edi
mov edx, eax
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x24]
call fcn.00472fc0
add esp, 8
mov esi, eax
push 0x54c6b8
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 4
call fcn.00471bb0
push 2
push esi
lea eax, [ebp - 0x1c]
mov byte [ebp - 4], 5
push eax
lea eax, [ebp - 0x14]
push eax
call fcn.00473100
mov byte [ebp - 4], 4
or ebx, 0xffffffff
mov edx, dword [ebp - 0x14]
mov eax, ebx
add edx, 0xfffffff0
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x478106
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 3
mov ecx, ebx
mov edx, dword [ebp - 0x24]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x478126
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 2
mov ecx, ebx
mov edx, dword [ebp - 0x28]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x478146
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 1
mov ecx, ebx
mov edx, dword [ebp - 0x18]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x478166
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0
mov ecx, ebx
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x478186
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x20]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x4781a7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp + 0xc]
push 0x14
push str.file_does_not_exists
call fcn.004725a0
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp + 0xc]
mov ecx, esi
push 1
call fcn.00477910
add esp, 4
test al, al
jne 0x478319
push str.directory_create_error:
lea ecx, [ebp - 0x1c]
call fcn.00471c70
push str.CopyFile
lea ecx, [ebp - 0x20]
mov dword [ebp - 4], 6
call fcn.00471bb0
mov byte [ebp - 4], 7
call fcn.00460220
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x478222
push 0x80004005
call fcn.004712d0
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
lea edi, [eax + 0x10]
mov dword [ebp - 0x28], edi
lea eax, [ebp - 0x1c]
mov byte [ebp - 4], 8
push eax
lea edx, [ebp - 0x28]
lea ecx, [ebp - 0x18]
call fcn.00472fc0
push esi
mov edx, eax
mov byte [ebp - 4], 9
lea ecx, [ebp - 0x24]
call fcn.00472fc0
push 2
mov edx, eax
mov byte [ebp - 4], 0xa
lea ecx, [ebp - 0x20]
call fcn.00473b30
mov byte [ebp - 4], 9
or ebx, 0xffffffff
mov edx, dword [ebp - 0x24]
add esp, 0xc
add edx, 0xfffffff0
mov eax, ebx
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x478287
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 8
mov ecx, ebx
mov edx, dword [ebp - 0x18]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4782a7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea edx, [edi - 0x10]
mov byte [ebp - 4], 7
lea eax, [edx + 0xc]
mov ecx, ebx
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4782c4
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 6
mov ecx, ebx
mov edx, dword [ebp - 0x20]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4782e4
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x478305
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
call fcn.00460220
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x478335
push 0x80004005
call fcn.004712d0
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 4], 0xb
push dword [eax]
lea eax, [ebp - 0x20]
push dword [esi]
push str._s_s
push eax
call fcn.00472d30
mov esi, dword [ebp - 0x20]
add esp, 0x10
push 0
push esi
push dword [edi]
call dword [sym.imp.KERNEL32.dll_CopyFileW]
or ebx, 0xffffffff
test eax, eax
jne 0x478422
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea ecx, [ebp - 0x30]
call fcn.00473060
mov edi, eax
push str.copyfile_failed_
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0xc
call fcn.00471c70
push edi
mov edx, eax
mov byte [ebp - 4], 0xd
lea ecx, [ebp - 0x14]
call fcn.00472fc0
add esp, 4
mov ecx, dword [ebp + 0xc]
push eax
mov byte [ebp - 4], 0xe
call fcn.00473a30
mov byte [ebp - 4], 0xd
mov ecx, ebx
mov edx, dword [ebp - 0x14]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4783dc
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0xc
mov ecx, ebx
mov edx, dword [ebp - 0x2c]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4783fc
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0xb
mov ecx, ebx
mov edx, dword [ebp - 0x30]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x47841c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 0xd], 0
jmp 0x478426
mov byte [ebp - 0xd], 1
add esi, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea eax, [esi + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x478444
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret