Function at 0x40c6f0
Capabilities:
Delete registry value
Query or enumerate registry value

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x5ac767
push eax
mov dword fs:[0], esp
sub esp, 0x82c
push ebx
call fcn.00434b00
neg eax
mov edx, dword [esp + 0x840]
lea ecx, [esp + 4]
sbb eax, eax
push ecx
and eax, 0x100
xor ebx, ebx
add eax, 0xf003f
push eax
push ebx
push str.SoftwareMicrosoftWindows_NTCurrentVersionAppCompatFlagsLayers
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40cac1
mov eax, dword [0x67a008]
mov dword [esp + 0x14], 0x800
cmp eax, ebx
jne 0x40c759
mov eax, 0x67a00c
lea ecx, [esp + 0x14]
lea edx, [esp + 0x30]
push ecx
push edx
push ebx
push ebx
push eax
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40c7db
lea ecx, [esp + 0x30]
push ecx
call fcn.0059330a
lea edx, [esp + 0x34]
push 0x64ffb8
push edx
call fcn.0057f137
add esp, 0xc
test eax, eax
jne 0x40c7c1
lea eax, [esp + 0x30]
push str.RUNAS
push eax
call fcn.0057f137
add esp, 8
test eax, eax
jne 0x40c7c1
lea ecx, [esp + 0x30]
push str.VISTA
push ecx
call fcn.0057f137
add esp, 8
test eax, eax
je 0x40c7db
mov eax, dword [0x67a008]
cmp eax, ebx
jne 0x40c7cf
mov eax, 0x67a00c
mov edx, dword [esp + 4]
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
xor ecx, ecx
mov dword [esp + 0x10], ebx
mov dword [esp + 8], ecx
mov word [esp + 0xc], bx
mov eax, dword [0x679ff8]
mov dword [esp + 0x838], ebx
cmp eax, ebx
jne 0x40c7ff
mov eax, 0x679ffc
mov edx, str._sUninstall.exe
push ebp
push esi
push edi
test edx, edx
je 0x40c8ec
cmp eax, ebx
je 0x40c8ec
push eax
lea ecx, [esp + 0x28]
mov dword [esp + 0x28], ebx
mov dword [esp + 0x30], ebx
mov word [esp + 0x2c], bx
call fcn.00401fb0
mov bl, 1
lea ecx, [esp + 0x14]
mov byte [esp + 0x844], bl
call fcn.00401070
push str._sUninstall.exe
lea ecx, [esp + 0x34]
call fcn.00401f20
mov esi, dword [esp + 0x38]
lea ecx, [esp + 0x24]
mov byte [esp + 0x844], 2
call fcn.00401fa0
push eax
call fcn.0057e90a
lea esi, [eax + esi + 2]
lea ebp, [esi + esi]
push ebp
call fcn.005970d9
mov edi, eax
add esp, 8
test edi, edi
mov dword [esp + 0x14], edi
je 0x40c8c5
mov ecx, ebp
xor eax, eax
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea ecx, [esp + 0x24]
call fcn.00401fa0
push eax
lea ecx, [esp + 0x34]
call fcn.00401fa0
push eax
mov eax, dword [esp + 0x1c]
push esi
push eax
call fcn.0057e89a
mov ecx, dword [esp + 0x24]
push ecx
call fcn.0057e90a
add esp, 0x14
mov dword [esp + 0x1c], eax
lea ecx, [esp + 0x30]
mov byte [esp + 0x844], bl
call fcn.00401070
lea ecx, [esp + 0x24]
mov byte [esp + 0x844], 0
call fcn.00401070
mov ecx, dword [esp + 0x14]
xor ebx, ebx
cmp ecx, ebx
mov dword [esp + 0x20], 0x800
mov eax, ecx
jne 0x40c8fe
lea eax, [esp + 0x18]
lea edx, [esp + 0x20]
lea ecx, [esp + 0x3c]
push edx
mov edx, dword [esp + 0x14]
push ecx
push ebx
push ebx
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40c952
lea eax, [esp + 0x3c]
push eax
call fcn.0059330a
lea ecx, [esp + 0x40]
push 0x64ffb8
push ecx
call fcn.0057f137
add esp, 0xc
test eax, eax
je 0x40c952
mov eax, dword [esp + 0x14]
cmp eax, ebx
jne 0x40c946
lea eax, [esp + 0x18]
mov edx, dword [esp + 0x10]
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov eax, dword [0x679ff8]
cmp eax, ebx
jne 0x40c960
mov eax, 0x679ffc
mov ecx, str._sIDMGrHlp.exe
test ecx, ecx
je 0x40ca37
cmp eax, ebx
je 0x40ca37
push eax
lea ecx, [esp + 0x28]
call fcn.00403ba0
lea ecx, [esp + 0x14]
mov byte [esp + 0x844], 3
call fcn.00401070
push str._sIDMGrHlp.exe
lea ecx, [esp + 0x34]
call fcn.00401f20
mov esi, dword [esp + 0x38]
lea ecx, [esp + 0x24]
mov byte [esp + 0x844], 4
call fcn.00401fa0
push eax
call fcn.0057e90a
lea esi, [eax + esi + 2]
lea ebp, [esi + esi]
push ebp
call fcn.005970d9
mov edi, eax
add esp, 8
cmp edi, ebx
mov dword [esp + 0x14], edi
je 0x40ca15
mov ecx, ebp
xor eax, eax
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea ecx, [esp + 0x24]
call fcn.00401fa0
push eax
lea ecx, [esp + 0x34]
call fcn.00401fa0
push eax
mov eax, dword [esp + 0x1c]
push esi
push eax
call fcn.0057e89a
mov ecx, dword [esp + 0x24]
push ecx
call fcn.0057e90a
add esp, 0x14
mov dword [esp + 0x1c], eax
lea ecx, [esp + 0x30]
mov byte [esp + 0x844], 3
call fcn.00401070
lea ecx, [esp + 0x24]
mov byte [esp + 0x844], 0
call fcn.00401070
mov eax, dword [esp + 0x14]
pop edi
pop esi
cmp eax, ebx
mov dword [esp + 0x18], 0x800
pop ebp
jne 0x40ca4e
lea eax, [esp + 0xc]
lea edx, [esp + 0x14]
lea ecx, [esp + 0x30]
push edx
mov edx, dword [esp + 8]
push ecx
push ebx
push ebx
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40caa2
lea eax, [esp + 0x30]
push eax
call fcn.0059330a
lea ecx, [esp + 0x34]
push 0x64ffb8
push ecx
call fcn.0057f137
add esp, 0xc
test eax, eax
je 0x40caa2
mov eax, dword [esp + 8]
cmp eax, ebx
jne 0x40ca96
lea eax, [esp + 0xc]
mov edx, dword [esp + 4]
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [esp + 8]
mov dword [esp + 0x838], 0xffffffff
call fcn.00401070
mov ecx, dword [esp + 0x830]
pop ebx
mov dword fs:[0], ecx
add esp, 0x838
ret