Function at 0x46a510
Capabilities:
Check if file exists
Copy file
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4daed4
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x52de08]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor ebx, ebx
mov dword [ebp - 0x10], ebx
test byte [0x52f5c4], 1
lea edi, [ebx + 1]
jne 0x46a57f
or dword [0x52f5c4], edi
mov dword [ebp - 4], edi
mov eax, dword [0x52ddd4]
mov edx, dword [eax + 0xc]
mov ecx, 0x52ddd4
call edx
add eax, 0x10
mov dword [0x52f5c0], eax
mov byte [ebp - 4], 1
push 0x4e5cb0
call fcn.004ac3db
add esp, 4
mov byte [ebp - 4], bl
mov ecx, dword [0x52f5c0]
cmp dword [ecx - 0xc], ebx
je 0x46a5b8
add ecx, 0xfffffff0
push ecx
call fcn.00406ee0
lea ecx, [eax + 0x10]
mov eax, dword [ebp + 8]
add esp, 4
mov dword [eax], ecx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x10], edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
cmp byte [0x52f519], 0
je 0x46a5da
mov esi, dword [ebp + 8]
push esi
mov ecx, 0x52f4b8
call fcn.004534f0
mov dword [ebp - 4], ebx
mov dword [ebp - 0x10], edi
jmp 0x46a855
mov eax, dword [ecx - 8]
mov edx, edi
sub edx, dword [ecx - 4]
mov edi, 0x104
sub eax, edi
or eax, edx
jge 0x46a5fe
push edi
mov ecx, 0x52f5c0
call fcn.00406e80
mov ecx, dword [0x52f5c0]
cmp dword [ecx - 8], edi
jge 0x46a60d
push 0x80070057
call fcn.00406170
mov dword [ecx - 0xc], edi
mov eax, dword [0x52f5c0]
push ecx
xor edx, edx
push edi
mov word [eax + 0x208], dx
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov eax, dword [0x52f5c0]
mov ecx, dword [eax - 8]
push ecx
push eax
call fcn.004ab44b
add esp, 8
cmp eax, ebx
jl 0x46a603
mov ecx, dword [0x52f5c0]
cmp eax, dword [ecx - 8]
jg 0x46a603
mov dword [ecx - 0xc], eax
mov edx, dword [0x52f5c0]
xor ecx, ecx
mov word [edx + eax*2], cx
mov eax, dword [0x52ddd4]
mov edx, dword [eax + 0xc]
mov ecx, 0x52ddd4
call edx
add eax, 0x10
mov dword [ebp - 0x14], eax
mov dword [ebp - 4], 6
lea eax, [ebp - 0x20]
push eax
mov ecx, esi
call fcn.00412d40
mov edi, eax
mov byte [ebp - 4], 7
lea ecx, [ebp - 0x1c]
push ecx
mov ecx, esi
call fcn.00412ce0
mov ebx, eax
mov byte [ebp - 4], 8
lea edx, [ebp - 0x18]
push edx
mov ecx, esi
call fcn.00442d60
mov byte [ebp - 4], 9
mov ecx, dword [edi]
mov edx, dword [ebx]
mov eax, dword [eax]
push ecx
push edx
push eax
lea ecx, [ebp - 0x14]
push str._s_s_s.exe
push ecx
call fcn.00407560
add esp, 0x14
mov byte [ebp - 4], 8
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x46a6e0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 7
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x46a703
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x46a726
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edi, dword [ebp - 0x14]
push edi
mov ecx, 0x52f5c0
call fcn.00412570
lea ecx, [ebp - 0x20]
push ecx
mov ecx, 0x52f4b8
call fcn.004534f0
mov byte [ebp - 4], 0xd
mov eax, dword [eax]
xor ecx, ecx
test eax, eax
setne cl
mov dword [ebp - 0x10], 2
test ecx, ecx
jne 0x46a764
push 0x80004005
call fcn.00406170
mov edx, dword [0x52f5c0]
push eax
push edx
call fcn.004ab66d
add esp, 8
test eax, eax
je 0x46a78c
mov eax, dword [0x52f5c0]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x46a78c
mov bl, 1
jmp 0x46a78e
xor bl, bl
mov dword [ebp - 4], 6
mov eax, 2
mov dword [ebp - 0x10], eax
and eax, 0xfffffffd
mov dword [ebp - 0x10], eax
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x46a7c6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test bl, bl
je 0x46a811
lea ecx, [ebp - 0x20]
push ecx
mov ecx, 0x52f4b8
call fcn.004534f0
mov byte [ebp - 4], 0xf
mov edx, dword [0x52f5c0]
mov eax, dword [eax]
push 0
push edx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
mov byte [ebp - 4], 6
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x46a811
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [0x52f5c0]
add eax, 0xfffffff0
push eax
call fcn.00406ee0
mov esi, dword [ebp + 8]
add eax, 0x10
add esp, 4
mov dword [esi], eax
mov byte [ebp - 4], 6
or dword [ebp - 0x10], 1
mov dword [ebp - 4], 0
lea eax, [edi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x46a855
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4