Function at 0x40a8b0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xa1c
mov eax, dword [0x42c008]
xor eax, esp
mov dword [esp + 0xa18], eax
push esi
push str.SetHPWMIEventRegistryValue___Thread_Start
lea eax, [esp + 0x14]
mov dword [esp + 0xc], edx
push 0x400
push eax
mov esi, ecx
call fcn.004011b0
add esp, 0xc
lea ecx, [esp + 0x10]
call fcn.004035d0
push 0x208
lea eax, [esp + 0x814]
push 0
push eax
call fcn.0040ce90
add esp, 0xc
lea eax, [esp + 0x810]
push str.CLSID60EB195D_B64E_4209_8AB8_53E040061B9CSystemEvent
push 0x4239b4
push 0x104
push eax
call fcn.00401120
lea eax, [esp + 0x820]
push eax
push str.RegOpenKeyEx_HKEY_CLASSES_ROOT__s
lea eax, [esp + 0x28]
push 0x400
push eax
call fcn.00401120
add esp, 0x20
lea ecx, [esp + 0x10]
call fcn.004035d0
lea eax, [esp + 0xc]
mov dword [esp + 0xc], 0
push eax
push 0x2001b
push 0
lea eax, [esp + 0x81c]
push eax
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x40a9f3
push eax
push str.RegOpenKeyEx_KEY_READKEY_SET_VALUE_fail_lRet_d
lea eax, [esp + 0x18]
push 0x400
push eax
call fcn.00401120
add esp, 0x10
lea ecx, [esp + 0x10]
call fcn.004035d0
lea eax, [esp + 0xc]
push eax
lea eax, [esp + 0x814]
push eax
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
je 0x40a9ea
push eax
push str.RegCreateKeyExW_fail_lRet_d_return_0
lea eax, [esp + 0x18]
push 0x400
push eax
call fcn.00401120
add esp, 0x10
lea ecx, [esp + 0x10]
call fcn.004035d0
xor eax, eax
pop esi
mov ecx, dword [esp + 0xa18]
xor ecx, esp
call fcn.0040aea4
mov esp, ebp
pop ebp
ret
push 0
push str.RegCreateKeyExW_success_lRet_d
jmp 0x40a9fa
push 0
push str.RegOpenKeyEx_KEY_READKEY_SET_VALUE_success_lRet_d
lea eax, [esp + 0x18]
push 0x400
push eax
call fcn.00401120
add esp, 0x10
lea ecx, [esp + 0x10]
call fcn.004035d0
cmp esi, 4
jne 0x40aa3d
push esi
lea eax, [esp + 0xc]
push eax
push esi
push 0
push str.ButtonID
push dword [esp + 0x20]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [esp + 8]
push str.ButtonID
jmp 0x40aab7
test esi, esi
jne 0x40aa65
push 4
lea eax, [esp + 0xc]
push eax
push 4
push esi
push str.HotKeyID
push dword [esp + 0x20]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [esp + 8]
push str.HotKeyID
jmp 0x40aab7
cmp esi, 3
jne 0x40aa8f
push 4
lea eax, [esp + 0xc]
push eax
push 4
push 0
push str.SmartAdapterCapacity
push dword [esp + 0x20]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [esp + 8]
push str.SmartAdapterCapacity
jmp 0x40aab7
cmp esi, 0x11
jne 0x40aae8
push 4
lea eax, [esp + 0xc]
push eax
push 4
push 0
push str.VisibleScreenSpace
push dword [esp + 0x20]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [esp + 8]
push str.VisibleScreenSpace
push str._s_RegSetValueEx_dwOutValue_d
mov esi, eax
lea eax, [esp + 0x1c]
push 0x400
push eax
call fcn.00401120
add esp, 0x14
lea ecx, [esp + 0x10]
call fcn.004035d0
test esi, esi
je 0x40aae8
push dword [esp + 8]
push str.RegSetValueEx_fail
jmp 0x40aaf1
push dword [esp + 8]
push str.RegSetValueEx_success
lea eax, [esp + 0x18]
push 0x400
push eax
call fcn.00401120
add esp, 0x10
lea ecx, [esp + 0x10]
call fcn.004035d0
cmp dword [esp + 0xc], 0
je 0x40ab3d
push 0x429b60
lea eax, [esp + 0x14]
push 0x400
push eax
call fcn.00401120
add esp, 0xc
lea ecx, [esp + 0x10]
call fcn.004035d0
push dword [esp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0xa1c]
xor eax, eax
pop esi
xor ecx, esp
call fcn.0040aea4
mov esp, ebp
pop ebp
ret