Function at 0x402541
Capabilities:
Check if file exists
Copy file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xe40
and word [ebp - 0x620], 0
push ebx
push esi
mov esi, 0x81
push edi
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x61e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ebx, 0x104
lea eax, [ebp - 0x620]
push ebx
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
and word [ebp - 0x828], 0
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x826]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push str.SafeCentral
lea eax, [ebp - 0x828]
push ebx
push eax
call fcn.0040278e
lea eax, [ebp - 0x620]
push 0x5c
push eax
call dword [sym.imp.MSVCRT.dll_wcsrchr]
xor edx, edx
add esp, 0x14
cmp eax, edx
je 0x402789
mov word [eax], dx
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0xe3e]
mov word [ebp - 0xe40], dx
mov word [ebp - 0xa30], dx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0xa2e]
push str.urlproc.dll
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edi, dword [sym.imp.MSVCRT.dll_swprintf]
lea eax, [ebp - 0x620]
push eax
lea eax, [ebp - 0xe40]
push str._s_s
push eax
call edi
add esp, 0x10
lea eax, [ebp - 0x828]
push str.urllib.dat
push eax
lea eax, [ebp - 0xa30]
push 0x404074
push eax
call edi
xor edx, edx
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0xc36]
mov word [ebp - 0xc38], dx
mov word [ebp - 0x418], dx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x416]
or dword [ebp - 4], 0xffffffff
rep stosd dword es:[edi], eax
add esp, 0x10
mov dword [ebp - 8], edx
stosw word es:[edi], ax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push eax
call fcn.0040131d
mov ecx, eax
call fcn.0040160d
test eax, eax
jne 0x4026c6
and word [ebp - 0x210], ax
mov ecx, esi
lea edi, [ebp - 0x20e]
push ebx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x210]
push eax
call fcn.0040131d
mov ecx, eax
call fcn.004013d1
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4026c6
lea eax, [ebp - 0x210]
push ebx
push eax
lea eax, [ebp - 0xa30]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
lea eax, [ebp - 0x418]
push ebx
push eax
lea eax, [ebp - 0xc38]
push ebx
push eax
call fcn.0040131d
mov ecx, eax
call fcn.0040143a
mov edi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
lea eax, [ebp - 0x418]
push eax
call edi
mov ebx, dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
jne 0x402710
lea eax, [ebp - 0x828]
push str.urllibauth.dat
push eax
lea eax, [ebp - 0x418]
push eax
call ebx
lea eax, [ebp - 0x418]
push eax
call edi
test eax, eax
jne 0x40275b
and word [ebp - 0x210], ax
mov ecx, esi
lea edi, [ebp - 0x20e]
push str.urllibauth.dat
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x620]
push eax
lea eax, [ebp - 0x210]
push eax
call ebx
lea eax, [ebp - 0x418]
push 1
push eax
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
push 1
lea eax, [ebp - 0x418]
push 0xffffffffffffffff
push eax
lea eax, [ebp - 0xc38]
push 0xffffffffffffffff
push eax
lea eax, [ebp - 0xa30]
push eax
lea eax, [ebp - 0xe40]
push eax
call fcn.00401b2e
mov ecx, eax
call fcn.00401c89
pop edi
pop esi
pop ebx
leave
ret