Function at 0x40c8ed
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x238
mov eax, dword [0x43c730]
xor eax, esp
mov dword [esp + 0x234], eax
push ebx
mov ebx, dword [esp + 0x240]
push esi
xor esi, esi
mov dword [esp + 0x2c], ebx
cmp ebx, esi
jne 0x40c851
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x234]
xor ecx, esp
call fcn.00422272
add esp, 0x238
ret
mov edx, dword [ebx + 0x6cc]
xor eax, eax
cmp edx, esi
mov dword [esp + 0xc], esi
jle 0x40c837
lea ecx, [ebx + 0x6d4]
test dword [ecx], 0xff00
jne 0x40c87c
inc eax
add ecx, 0x2a4
cmp eax, edx
jl 0x40c867
jmp 0x40c837
mov ecx, eax
imul ecx, ecx, 0x2a4
push edi
mov edi, dword [ecx + ebx + 0x6d4]
mov ecx, dword [0x43bbcc]
cmp ecx, esi
mov dword [esp + 0x2c], edi
mov dword [esp + 0xc], eax
jle 0x40c8b0
mov eax, 0x43bbec
mov dword [eax - 4], esi
mov dword [eax], esi
add eax, 0x20
sub ecx, 1
jne 0x40c8a3
lea edx, [esp + 0x10]
push ebp
push edx
call fcn.00401c40
mov edx, dword [0x43bbcc]
add esp, 4
cmp edx, esi
mov ebp, eax
mov dword [esp + 0x18], ebp
jle 0x40c8fb
mov esi, dword [esp + 0x14]
mov eax, 0x43bbd0
mov ecx, dword [eax + 4]
cmp ecx, 0x40
ja case.0x40c8e6.3
movzx ecx, byte [ecx + 0x40cc50]
jmp dword [ecx*4 + 0x40cc44]
mov dword [eax], edi
jmp case.0x40c8e6.3
mov dword [eax], esi
add eax, 0x20
sub edx, 1
jne 0x40c8d7
cmp ebp, 1
jne 0x40c94e
cmp dword [ebx + 8], 4
jne 0x40c92e
cmp dword [ebx + 0x12a0c], 2
jne 0x40c94e
xor eax, eax
lea ecx, [ebx + 0x12a14]
mov edx, dword [ecx]
test edx, edx
je 0x40c925
test dword [edx], 0xff00
jne 0x40c94e
inc eax
add ecx, 0x78
cmp eax, 2
jl 0x40c917
mov eax, dword [ebx + 0x12b08]
lea edx, [esp + 0x14]
push edx
push eax
mov dword [esp + 0x1c], 0
call fcn.00401cd0
add esp, 8
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x10]
imul ecx, ecx, 0x2a4
cmp dword [ecx + ebx + 0x718], 0
lea ebp, [ecx + ebx + 0x6d4]
jne 0x40c9e8
xor edi, edi
cmp dword [0x43bbcc], edi
jle 0x40c9d8
mov esi, 0x43bbd4
jmp 0x40c980
mov edx, dword [esi]
mov eax, 1
cmp edx, dword [ebp + 0x48]
jne 0x40c998
mov dword [esi + 0x14], eax
mov dword [esi + 0x18], eax
mov ecx, dword [ebp]
mov dword [esi - 4], ecx
cmp dword [esp + 0x18], eax
jne 0x40c9cc
push ebx
call fcn.0040b3e0
add esp, 4
test eax, eax
jne 0x40c9b9
cmp dword [esi], 0x20
jne 0x40c9cc
mov edx, dword [esp + 0x14]
mov dword [esi - 4], edx
jmp 0x40c9c5
cmp dword [esi], 0x40
jne 0x40c9cc
mov eax, dword [esp + 0x14]
mov dword [esi - 4], eax
mov dword [esi + 0x14], 1
inc edi
add esi, 0x20
cmp edi, dword [0x43bbcc]
jl 0x40c980
cmp dword [esp + 0x18], 1
je 0x40c9e8
mov eax, dword [esp + 0x10]
jmp 0x40cc29
mov ecx, dword [0x43bbcc]
test ecx, ecx
jle 0x40ca0e
mov eax, 0x43bbe8
jmp 0x40ca00
mov dword [eax], 0
add eax, 0x20
sub ecx, 1
jne 0x40ca00
mov edx, dword [0x43bd30]
xor edi, edi
xor eax, eax
cmp edx, edi
mov dword [esp + 0x24], edi
mov dword [esp + 0x10], edi
jle 0x40ca51
mov esi, dword [ebp + 0x40]
jmp 0x40ca30
mov ecx, dword [eax*4 + 0x43bd18]
mov ebx, 1
shl ebx, cl
test esi, ebx
jne 0x40ca49
inc eax
cmp eax, edx
jl 0x40ca30
jmp 0x40ca51
mov dword [esp + 0x24], 1
mov esi, dword [0x43bd50]
xor eax, eax
cmp esi, edi
jle 0x40ca81
mov edx, dword [ebp + 0x40]
mov ecx, dword [eax*4 + str._b_t_n_v_f_r]
mov edi, 1
shl edi, cl
test edx, edi
jne 0x40ca79
inc eax
cmp eax, esi
jl 0x40ca60
jmp 0x40ca81
mov dword [esp + 0x10], 1
xor edi, edi
push 0x206
lea edx, [esp + 0x42]
xor ecx, ecx
push edi
push edx
mov dword [esp + 0x34], edi
xor ebx, ebx
xor ebp, ebp
mov dword [esp + 0x38], edi
mov dword [esp + 0x28], edi
mov word [esp + 0x48], cx
call fcn.00422290
add esp, 0xc
push str.SOFTWARENVIDIA_CorporationGlobal
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0x4343ec
lea ecx, [esp + 0x40]
push ecx
call esi
push str.NVTweak
lea edx, [esp + 0x40]
push edx
call esi
lea eax, [esp + 0x1c]
push eax
mov esi, 1
push esi
push edi
lea ecx, [esp + 0x48]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40cb5d
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x38]
push edx
lea eax, [esp + 0x24]
push eax
push edi
push edi
push str.NvCplDisableTvVideoOutputFormats
push ecx
mov dword [esp + 0x38], edi
mov dword [esp + 0x50], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40cb4e
mov eax, dword [esp + 0x20]
and eax, 0x1f
mov dword [esp + 0x20], eax
test al, 0x10
je 0x40cb3a
mov dword [esp + 0x2c], esi
test al, 1
je 0x40cb42
mov dword [esp + 0x28], esi
test al, 2
je 0x40cb48
mov ebx, esi
test al, 4
je 0x40cb4e
mov ebp, esi
mov edx, dword [esp + 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [esp + 0x1c], edi
xor edi, edi
cmp dword [0x43bbcc], edi
jle 0x40cc26
mov esi, 0x43bbd4
mov eax, dword [esi]
cmp eax, 0x10
ja case.0x40cb7e.3
movzx ecx, byte [eax + 0x40cc9c]
jmp dword [ecx*4 + 0x40cc94]
mov edx, dword [esp + 0x30]
mov dword [esi - 4], edx
test eax, eax
jne 0x40cbac
cmp dword [esp + 0x24], eax
je 0x40cbd3
cmp dword [esp + 0x10], eax
jne 0x40cbac
cmp dword [esp + 0x28], eax
jne 0x40cbac
mov ecx, 1
mov dword [esi + 0x14], ecx
jmp 0x40cbb1
mov ecx, 1
cmp dword [esp + 0x24], 0
je 0x40cbd8
cmp eax, 2
jne 0x40cbc6
test ebx, ebx
jne 0x40cbc6
mov dword [esi + 0x14], ecx
jmp 0x40cbd8
cmp eax, ecx
jne 0x40cbd8
test ebp, ebp
jne 0x40cbd8
mov dword [esi + 0x14], ecx
jmp 0x40cbd8
mov ecx, 1
cmp dword [esp + 0x10], 0
je 0x40cbee
cmp eax, 8
jne 0x40cbee
cmp dword [esp + 0x2c], 0
jne 0x40cbee
mov dword [esi + 0x14], ecx
cmp dword [esp + 0x18], ecx
jne 0x40cc16
mov eax, dword [esp + 0x34]
push eax
call fcn.0040b3e0
add esp, 4
test eax, eax
jne 0x40cc0a
cmp dword [esi], 0x20
jmp 0x40cc0d
cmp dword [esi], 0x40
jne 0x40cc16
mov dword [esi + 0x14], 1
inc edi
add esi, 0x20
cmp edi, dword [0x43bbcc]
jl 0x40cb70
or eax, 0xffffffff
mov ecx, dword [esp + 0x244]
pop ebp
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00422272
add esp, 0x238
ret