Function at 0x40a9e0
Capabilities:
Query or enumerate registry key
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x45bd11
mov eax, dword fs:[0]
push eax
sub esp, 0x1b4
mov eax, dword [0x491104]
xor eax, esp
mov dword [esp + 0x1b0], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x491104]
xor eax, esp
push eax
lea eax, [esp + 0x1c8]
mov dword fs:[0], eax
mov eax, dword [esp + 0x1d8]
mov ebp, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
xor ebx, ebx
mov edi, ecx
mov dword [esp + 0x2c], eax
mov byte [esp + 0x17], bl
mov byte [esp + 0x16], bl
xor esi, esi
lea ecx, [esp + 0x1c]
push ecx
mov ecx, dword [edi]
push ebx
push ebx
push ebx
lea edx, [esp + 0x40]
push edx
lea eax, [esp + 0x48]
push eax
push esi
push ecx
mov dword [esp + 0x50], 0xc8
call ebp
test eax, eax
jne 0x40aa97
lea edx, [esp + 0x34]
push str.ItssRestrictions
push edx
call fcn.00442ec2
add esp, 8
test eax, eax
jne 0x40aa79
mov byte [esp + 0x17], 1
lea eax, [esp + 0x34]
push str.HHRestrictions
push eax
call fcn.00442ec2
add esp, 8
test eax, eax
jne 0x40aa94
mov byte [esp + 0x16], 1
inc esi
jmp 0x40aa3a
mov esi, dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov ebp, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp byte [esp + 0x17], bl
jne 0x40ab1c
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1d0], ebx
mov eax, dword [edi]
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x1c]
push edx
push ebx
push 0x2001f
push ebx
push ebx
push ebx
push str.ItssRestrictions
push eax
mov dword [esp + 0x3c], ebx
call esi
cmp eax, ebx
jne 0x40ac5d
mov eax, dword [esp + 0x18]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ebx
cmp eax, ebx
je 0x40aafe
push eax
call ebp
xor eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1d0], 0xffffffff
cmp eax, ebx
je 0x40ab18
push eax
call ebp
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
cmp byte [esp + 0x16], bl
jne 0x40ab99
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1d0], 1
mov eax, dword [edi]
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x1c]
push edx
push ebx
push 0x2001f
push ebx
push ebx
push ebx
push str.HHRestrictions
push eax
mov dword [esp + 0x3c], ebx
call esi
cmp eax, ebx
jne 0x40ac8d
mov eax, dword [esp + 0x18]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ebx
cmp eax, ebx
je 0x40ab7b
push eax
call ebp
xor eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1d0], 0xffffffff
cmp eax, ebx
je 0x40ab95
push eax
call ebp
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov eax, dword [edi]
cmp eax, ebx
je 0x40aba4
push eax
call ebp
mov dword [edi], ebx
mov dword [edi + 4], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x1d0], 2
mov edi, dword [esp + 0x1dc]
lea ecx, [esp + 0x18]
push ecx
push edi
push ebx
push str.SOFTWAREMicrosoftHTMLHelp1.xItssRestrictions
push 0x80000002
mov dword [esp + 0x2c], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
jne 0x40ac94
mov esi, dword [esp + 0x18]
push 4
lea ecx, [esp + 0x1c]
push ecx
push 4
push ebx
mov edx, edi
push str.MaxAllowedZone
and edx, 0x300
mov dword [esp + 0x3c], ebx
push esi
mov dword [esp + 0x3c], esi
mov dword [esp + 0x40], edx
mov dword [esp + 0x30], 1
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x40acc4
mov edx, dword [esp + 0x2c]
push str.Can_set__MaxAllowedZone_registry_key_nSOFTWAREMicrosoftHTMLHelp1.xItssRestrictionsMaxAllowedZone_nPlease_check_if_you_have_admin_rights.
push 0x168
push edx
call fcn.0044376b
add esp, 0xc
mov dword [esp + 0x1d0], 0xffffffff
cmp esi, ebx
je 0x40ac4f
push esi
call ebp
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov eax, 0x29
jmp 0x40ad86
push str.Can_not_create_sub_key_ItssRestrictions_registry_key_nSOFTWAREMicrosoftHTMLHelp1.xItssRestrictions_nPlease_check_if_you_have_admin_rights.
mov eax, dword [esp + 0x30]
push 0x168
push eax
call fcn.0044376b
add esp, 0xc
mov dword [esp + 0x1d0], 0xffffffff
mov dword [esp + 0x20], ebx
mov eax, 0x1e
jmp 0x40ad86
push str.Can_not_create_sub_key_HHRestrictions_registry_key_nSOFTWAREMicrosoftHTMLHelp1.xHHRestrictions_nPlease_check_if_you_have_admin_rights.
jmp 0x40ac62
mov eax, dword [esp + 0x2c]
push str.Can_not_access_registry_key_nSOFTWAREMicrosoftHTMLHelp1.xItssRestrictions_nPlease_check_if_you_have_admin_rights.
push 0x168
push eax
call fcn.0044376b
add esp, 0xc
mov dword [esp + 0x1d0], 0xffffffff
mov dword [esp + 0x28], ebx
mov eax, 0x28
jmp 0x40ad86
cmp esi, ebx
je 0x40accf
push esi
call ebp
mov dword [esp + 0x24], ebx
mov eax, edi
mov ecx, str.SOFTWAREMicrosoftHTMLHelp1.xHHRestrictions
mov edx, 0x80000002
lea esi, [esp + 0x24]
mov dword [esp + 0x28], ebx
call fcn.00401210
test eax, eax
je 0x40ad28
mov eax, dword [esp + 0x2c]
push str.Can_not_access_registry_key_nSOFTWAREMicrosoftHTMLHelp1.xHHRestrictions_nPlease_check_if_you_have_admin_rights.
push 0x168
push eax
call fcn.0044376b
add esp, 0xc
mov dword [esp + 0x1d0], 0xffffffff
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x40ad1d
push eax
call ebp
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov eax, 0x28
jmp 0x40ad86
lea ecx, [esp + 0x24]
call fcn.0040a9b0
test eax, eax
je 0x40ad67
mov ecx, dword [esp + 0x2c]
push str.Can_set__MaxAllowedZone_registry_key_nSOFTWAREMicrosoftHTMLHelp1.xHHRestrictionsMaxAllowedZone_nPlease_check_if_you_have_admin_rights.
push 0x168
push ecx
call fcn.0044376b
add esp, 0xc
mov dword [esp + 0x1d0], 0xffffffff
lea ecx, [esp + 0x24]
call fcn.004011c0
mov eax, 0x29
jmp 0x40ad86
lea ecx, [esp + 0x24]
call fcn.004011e0
mov dword [esp + 0x1d0], 0xffffffff
lea ecx, [esp + 0x24]
call fcn.004011c0
xor eax, eax
mov ecx, dword [esp + 0x1c8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x1b0]
xor ecx, esp
call fcn.00442851
add esp, 0x1c0
ret