Function at 0x40297a
Capabilities:
Persist via run registry key

Disassembly:
mov eax, 0x41bfe8
call fcn.0041baa0
sub esp, 0x230
and byte [ebp - 0xe], 0
and byte [ebp - 0xd], 0
push ebx
push esi
push edi
call fcn.0041849a
test al, al
jne 0x402a35
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea eax, [ebp - 0x14]
mov ebx, 0x2001f
push eax
push ebx
push 0
mov edi, SysReAllocStringLen
push 0x427acc
push edi
call esi
cmp eax, 5
jne 0x4029e6
push ecx
mov byte [ebp - 0xd], 1
mov ecx, esp
mov dword [ebp - 0x18], esp
push str.create_uninstall_key_
call sub.MFC42.DLL_CString::CString_1
push dword [ebp + 8]
call fcn.0040281f
pop ecx
pop ecx
jmp 0x4029f3
test eax, eax
jne 0x4029f3
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x14]
push eax
push ebx
push 0
push 0x427a84
push edi
call esi
cmp eax, 5
jne 0x402a28
push ecx
mov byte [ebp - 0xd], 1
mov ecx, esp
mov dword [ebp - 0x18], esp
push str.add_run_key_
call sub.MFC42.DLL_CString::CString_1
mov ebx, dword [ebp + 8]
push ebx
call fcn.0040281f
pop ecx
pop ecx
jmp 0x402a38
test eax, eax
jne 0x402a35
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ebx, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x20]
push eax
push 1
pop edi
push edi
push 0xa
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenThreadToken]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x402ab2
call esi
cmp eax, 0x78
je 0x402bb3
call esi
cmp eax, 0x3f0
je 0x402a8b
call esi
push ecx
mov ecx, esp
mov dword [ebp + 8], esp
push eax
push str.get_AccessCheck_Token___d__
jmp 0x402b00
lea eax, [ebp - 0x20]
push eax
push 0xa
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x402ab2
call esi
push ecx
mov ecx, esp
mov dword [ebp + 8], esp
push eax
push str.copy_AccessCheck_Token___d__
jmp 0x402b00
lea eax, [ebp - 0x1c]
push eax
push 2
push dword [ebp - 0x20]
call dword [sym.imp.ADVAPI32.dll_DuplicateToken]
test eax, eax
jne 0x402ad5
call esi
push ecx
mov ecx, esp
mov dword [ebp + 8], esp
push eax
push str.duplicate_AccessCheck_Token___d__
jmp 0x402b00
and byte [ebp - 0x128], 0
lea eax, [ebp - 0x128]
push eax
call fcn.0041a020
cmp byte [ebp - 0x128], 0
pop ecx
jne 0x402b16
call esi
push ecx
mov ecx, esp
mov dword [ebp + 8], esp
push eax
push str.get_pf_directory___d__
push ecx
call fcn.004125f6
add esp, 0xc
push ebx
call fcn.0040281f
pop ecx
pop ecx
jmp 0x402bb3
call fcn.0041849a
test al, al
jne 0x402bb3
push ebx
lea eax, [ebp - 0x128]
push dword [ebp - 0x1c]
push str.ProgramFiles
push eax
call fcn.00402875
add esp, 0x10
test al, al
je 0x402bac
mov esi, 0x113
lea eax, [ebp - 0x23c]
push esi
push 0
push eax
mov dword [ebp - 0x14], edi
call sub.MSVCRT.dll_memset
push 0
push edi
lea eax, [ebp - 0x23c]
push esi
push eax
call fcn.004191bd
add esp, 0x1c
lea eax, [ebp - 0x23c]
lea ecx, [ebp + 8]
push eax
call sub.MFC42.DLL_CString::CString_1
push ebx
and dword [ebp - 4], 0
push dword [ebp - 0x1c]
push str.Temp
push dword [ebp + 8]
call fcn.00402875
add esp, 0x10
mov dword [ebp - 0x18], edi
test al, al
jne 0x402b9e
mov dword [ebp - 0x18], 2
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call sub.MFC42.DLL_CString::CString
jmp 0x402bb3
mov dword [ebp - 0x14], 2
cmp dword [ebp - 0x1c], 0
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
je 0x402bc4
push dword [ebp - 0x1c]
call esi
cmp dword [ebp - 0x20], 0
je 0x402bcf
push dword [ebp - 0x20]
call esi
call fcn.0041849a
test al, al
jne 0x402bec
cmp dword [ebp - 0x14], 2
jne 0x402be2
mov byte [ebp - 0xe], 1
cmp dword [ebp - 0x18], 2
jne 0x402bec
mov byte [ebp - 0xe], 1
mov esi, 0x4279dc
mov ecx, ebx
push esi
call sub.MFC42.DLL_CString::Find_2
test eax, eax
jl 0x402c44
mov edi, eax
inc eax
push eax
push esi
mov ecx, ebx
call sub.MFC42.DLL_CString::Find_1
test eax, eax
jge 0x402bfd
test edi, edi
jl 0x402c44
mov eax, dword [ebx]
mov eax, dword [eax - 8]
add eax, 0xfffffffd
cmp edi, eax
jle 0x402c44
lea eax, [ebp - 0x24]
push edi
push eax
mov ecx, ebx
call sub.MFC42.DLL_CString::Left
push eax
mov ecx, ebx
mov dword [ebp - 4], 1
call sub.MFC42.DLL_CString::operator_3
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::CString
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
or al, byte [ebp - 0xe]
pop edi
pop esi
mov dword fs:[0], ecx
neg al
sbb eax, eax
pop ebx
inc eax
leave
ret