Function at 0x405460
Capabilities:
Check if file exists
Check os version
Copy file
Get common file path
Move file
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x469997
mov eax, dword fs:[0]
push eax
sub esp, 0x4b8
mov eax, dword [0x4832f0]
xor eax, esp
mov dword [esp + 0x4b0], eax
push ebx
push esi
push edi
mov eax, dword [0x4832f0]
xor eax, esp
push eax
lea eax, [esp + 0x4c8]
mov dword fs:[0], eax
mov edi, 7
xor ebx, ebx
xor eax, eax
mov dword [esp + 0xa8], edi
mov dword [esp + 0xa4], ebx
mov word [esp + 0x94], ax
mov dword [esp + 0x4d0], ebx
xor ecx, ecx
mov dword [esp + 0x8c], edi
mov dword [esp + 0x88], ebx
mov word [esp + 0x78], cx
push 0x208
lea edx, [esp + 0xb0]
push ebx
push edx
mov byte [esp + 0x4dc], 1
call fcn.0044e9d0
add esp, 0xc
push 0x208
lea eax, [esp + 0x2b8]
push ebx
push eax
call fcn.0044e9d0
add esp, 0xc
lea ecx, [esp + 0x90]
mov dword [esp + 0x18], ebx
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], str._safemonhlp.dll
mov dword [esp + 0x20], str._sesafepro.dll
mov dword [esp + 0x24], str.uniconft.dll
mov dword [esp + 0x28], str.WdHPFileSafe.dll
mov dword [esp + 0x2c], str.urlproc.dll
mov dword [esp + 0x30], str._frag.dat
mov dword [esp + 0x34], str._fragex.dat
mov dword [esp + 0x38], str.wd.ini
call fcn.004090f0
test eax, eax
jne 0x4055b7
mov esi, 8
cmp dword [esp + 0x8c], esi
jb 0x405582
mov ecx, dword [esp + 0x78]
push ecx
call fcn.0044b6e3
add esp, 4
xor edx, edx
mov dword [esp + 0x8c], edi
mov dword [esp + 0x88], ebx
mov word [esp + 0x78], dx
cmp dword [esp + 0xa8], esi
jb 0x4055b0
mov eax, dword [esp + 0x94]
push eax
call fcn.0044b6e3
add esp, 4
xor eax, eax
jmp 0x405941
lea ecx, [esp + 0x74]
call fcn.004090f0
test eax, eax
jne 0x4055d5
push ebx
push 0x474a60
lea esi, [esp + 0x7c]
call fcn.004018a0
jmp 0x405567
push 9
push str.Download
lea eax, [esp + 0x7c]
call fcn.00405090
lea ecx, [esp + 0xac]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
xor edi, edi
mov dword [esp + 0x14], edi
push 0xffffffffffffffff
push ebx
lea eax, [esp + 0x98]
xor edx, edx
push eax
mov esi, 7
lea eax, [esp + 0x64]
mov dword [esp + 0x7c], esi
mov dword [esp + 0x78], ebx
mov word [esp + 0x68], dx
call fcn.00401950
push 0xffffffffffffffff
mov byte [esp + 0x4d4], 2
push ebx
lea edx, [esp + 0x7c]
xor ecx, ecx
push edx
lea eax, [esp + 0x48]
mov dword [esp + 0x60], esi
mov dword [esp + 0x5c], ebx
mov word [esp + 0x4c], cx
call fcn.00401950
mov byte [esp + 0x4d0], 3
mov esi, dword [esp + edi*4 + 0x1c]
mov eax, esi
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x405660
sub eax, edx
sar eax, 1
push eax
push esi
lea eax, [esp + 0x60]
call fcn.00405090
mov eax, esi
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x405680
sub eax, edx
sar eax, 1
push eax
push esi
lea eax, [esp + 0x44]
call fcn.00405090
mov eax, dword [esp + 0x40]
mov esi, 8
cmp dword [esp + 0x54], esi
jae 0x4056ad
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x405839
mov eax, dword [esp + 0x40]
cmp dword [esp + 0x54], esi
jae 0x4056ca
lea eax, [esp + 0x40]
push eax
call fcn.0042b3f0
add esp, 4
test eax, eax
je 0x405745
mov edi, dword [esp + 0x40]
cmp dword [esp + 0x54], esi
jae 0x4056e5
lea edi, [esp + 0x40]
push 0x4dfa00
call fcn.00403570
test eax, eax
je 0x405839
mov eax, dword [esp + 0x5c]
mov ecx, esi
cmp dword [esp + 0x70], ecx
jae 0x405707
lea eax, [esp + 0x5c]
cmp dword [esp + 0x54], ecx
mov ecx, dword [esp + 0x40]
jae 0x405715
lea ecx, [esp + 0x40]
push eax
call fcn.00432d10
add esp, 4
test eax, eax
jne 0x405741
lea esi, [esp + 0x3c]
call fcn.00402290
lea esi, [esp + 0x58]
mov byte [esp + 0x4d0], 1
call fcn.00402290
jmp 0x40587a
mov edi, dword [esp + 0x14]
mov ecx, dword [esp + 0x5c]
cmp dword [esp + 0x70], esi
jae 0x405753
lea ecx, [esp + 0x5c]
mov eax, dword [esp + 0x40]
cmp dword [esp + 0x54], esi
jae 0x405761
lea eax, [esp + 0x40]
push ebx
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
mov dword [esp + 0x18], eax
cmp eax, ebx
jne 0x4057da
lea eax, [esp + 0x2b4]
push eax
push ebx
push 0x474654
lea ecx, [esp + 0xb8]
push ecx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
mov eax, dword [esp + 0x5c]
cmp dword [esp + 0x70], esi
jae 0x40579c
lea eax, [esp + 0x5c]
push 3
lea edx, [esp + 0x2b8]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov ecx, dword [esp + 0x5c]
cmp dword [esp + 0x70], esi
jae 0x4057bb
lea ecx, [esp + 0x5c]
mov eax, dword [esp + 0x40]
cmp dword [esp + 0x54], esi
jae 0x4057c9
lea eax, [esp + 0x40]
push ebx
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
mov dword [esp + 0x18], eax
cmp eax, ebx
je 0x405839
cmp edi, ebx
jne 0x4057e5
or dword [esp + 0x10], 1
jmp 0x405839
cmp edi, 1
jne 0x4057f1
or dword [esp + 0x10], 2
jmp 0x405839
cmp edi, 2
jne 0x4057fd
or dword [esp + 0x10], 4
jmp 0x405839
cmp edi, 3
jne 0x405808
or dword [esp + 0x10], esi
jmp 0x405839
cmp edi, 4
jne 0x405814
or dword [esp + 0x10], 0x10
jmp 0x405839
cmp edi, 5
jne 0x405820
or dword [esp + 0x10], 0x20
jmp 0x405839
cmp edi, 6
jne 0x40582c
or dword [esp + 0x10], 0x40
jmp 0x405839
cmp edi, 7
jne 0x405839
or dword [esp + 0x10], 0x80
cmp dword [esp + 0x54], esi
jb 0x40584c
mov eax, dword [esp + 0x40]
push eax
call fcn.0044b6e3
add esp, 4
mov byte [esp + 0x4d0], 1
xor ecx, ecx
mov dword [esp + 0x54], 7
mov dword [esp + 0x50], ebx
mov word [esp + 0x40], cx
cmp dword [esp + 0x70], esi
jb 0x40587a
mov edx, dword [esp + 0x5c]
push edx
call fcn.0044b6e3
add esp, 4
mov edi, dword [esp + 0x14]
inc edi
mov dword [esp + 0x14], edi
cmp edi, 8
jb 0x4055fe
mov eax, dword [esp + 0x10]
mov edi, 7
cmp eax, ebx
je 0x4058f4
push eax
sub esp, 0x1c
mov esi, esp
mov dword [esp + 0x34], esp
push 0xd
xor eax, eax
mov dword [esi + 0x18], edi
mov dword [esi + 0x14], ebx
push str.UpNetGuardRet
mov word [esi + 4], ax
call fcn.004018a0
sub esp, 0x1c
mov esi, esp
mov dword [esp + 0x4c], esp
mov byte [esp + 0x50c], 4
push 0xa
xor ecx, ecx
mov dword [esi + 0x18], edi
mov dword [esi + 0x14], ebx
push str.UpNetGuard
mov word [esi + 4], cx
call fcn.004018a0
mov byte [esp + 0x50c], 1
call fcn.00402b90
add esp, 0x3c
mov esi, 8
cmp dword [esp + 0x8c], esi
jb 0x40590f
mov edx, dword [esp + 0x78]
push edx
call fcn.0044b6e3
add esp, 4
xor eax, eax
mov dword [esp + 0x8c], edi
mov dword [esp + 0x88], ebx
mov word [esp + 0x78], ax
cmp dword [esp + 0xa8], esi
jb 0x40593d
mov ecx, dword [esp + 0x94]
push ecx
call fcn.0044b6e3
add esp, 4
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x4c8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4b0]
xor ecx, esp
call fcn.0044b6ee
mov esp, ebp
pop ebp
ret