Function at 0x402608
Capabilities:
Copy file
Get common file path
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x63c
push ebx
and byte [ebp - 0x228], 0
push esi
push edi
lea eax, [ebp - 0x430]
push 0x104
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x430]
push eax
call fcn.00403560
lea eax, [ebp - 0x32c]
xor edi, edi
push eax
push edi
lea eax, [ebp - 0x430]
push 0x4014ec
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
lea eax, [ebp - 0x32c]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [ebp - 0x32c]
push edi
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CopyFileA]
push edi
push edi
call fcn.0040396e
test eax, eax
mov eax, 0x4014d4
jne 0x402690
mov eax, 0x4014c0
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
push eax
lea eax, [ebp - 0x534]
push eax
call esi
push edi
push dword [ebp + 0x10]
call fcn.00402c55
mov dword [ebp + 8], eax
lea eax, [ebp - 0x63c]
push eax
push dword [ebp + 0x10]
call fcn.004035ba
test eax, eax
je 0x402714
lea eax, [ebp - 0x63c]
push 0x4014ac
push eax
call fcn.00403529
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x63c]
push eax
call fcn.004029c0
test eax, eax
je 0x402714
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcmpiA]
mov edi, 0x4014a4
lea eax, [ebp - 0x20]
push edi
push eax
call ebx
test eax, eax
je 0x40270a
mov edi, 0x40149c
lea eax, [ebp - 0x20]
push edi
push eax
call ebx
test eax, eax
jne 0x402714
lea eax, [ebp - 0x228]
push edi
push eax
call esi
cmp byte [ebp - 0x228], 0
mov edi, dword [sym.imp.KERNEL32.dll_lstrcatA]
mov ebx, 0x401498
je 0x402742
lea eax, [ebp - 0x534]
push ebx
push eax
call edi
lea eax, [ebp - 0x228]
push eax
lea eax, [ebp - 0x534]
push eax
call edi
lea eax, [ebp - 0x228]
push eax
push dword [ebp + 0x10]
call fcn.00402ae6
call fcn.00403bc3
push 0
push 0
mov dword [ebp + 0xc], eax
call fcn.0040396e
test eax, eax
je 0x4027b3
lea eax, [ebp - 0x124]
push 0x401480
push eax
call esi
cmp byte [ebp - 0x228], 0
je 0x402797
lea eax, [ebp - 0x124]
push ebx
push eax
call edi
lea eax, [ebp - 0x228]
push eax
lea eax, [ebp - 0x124]
push eax
call edi
lea eax, [ebp - 0x430]
push 0
push eax
lea eax, [ebp - 0x124]
push eax
lea eax, [ebp - 0x32c]
push eax
call fcn.00403e01
push dword [ebp + 0x10]
call fcn.004037e4
lea eax, [ebp - 0x124]
push 0x401470
push eax
call esi
cmp byte [ebp - 0x228], 0
je 0x4027ec
lea eax, [ebp - 0x124]
push ebx
push eax
call edi
lea eax, [ebp - 0x228]
push eax
lea eax, [ebp - 0x124]
push eax
call edi
lea eax, [ebp - 0x430]
push 4
push eax
lea eax, [ebp - 0x124]
push eax
lea eax, [ebp - 0x32c]
push eax
call fcn.00403e01
push dword [ebp + 0x10]
lea eax, [ebp - 0x124]
push eax
call esi
lea eax, [ebp - 0x124]
push 0x401460
push eax
call fcn.00403529
lea eax, [ebp - 0x124]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
test esi, esi
je 0x40284e
push 0xb
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x402847
call eax
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push 1
pop ebx
test byte [0x405114], bl
je 0x40285d
push 4
jmp 0x40285f
push 0
lea eax, [ebp - 0x430]
push eax
lea eax, [ebp - 0x534]
push eax
lea eax, [ebp - 0x32c]
push eax
call fcn.00403e01
mov edi, eax
lea eax, [ebp - 0x430]
push eax
push dword [ebp + 8]
call fcn.004028e3
push dword [ebp + 0xc]
call fcn.00403bb0
test eax, eax
je 0x40289b
mov eax, dword [ebp + 0x14]
mov dword [eax], ebx
push 0x401458
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x4028b2
call fcn.00402bae
mov esi, SysStringLen
push 0x4012a4
push esi
call fcn.00404233
push 0x401440
push esi
call fcn.00404233
lea eax, [ebp - 0x32c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 0x10