Function at 0x140032ea0
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push rbp
push rsi
push r12
lea rbp, [rsp - 0x47]
sub rsp, 0x90
mov rax, qword [0x14009f008]
xor rax, rsp
mov qword [rbp + 0x2f], rax
mov rsi, rcx
lea rdx, [rbp + 0x17]
xor r12d, r12d
xor ecx, ecx
mov qword [rbp + 0x17], r12
call qword [sym.imp.POWRPROF.dll_PowerGetActiveScheme]
test eax, eax
jne 0x14003311d
mov rdx, qword [rbp + 0x17]
lea r9, [0x140085ba0]
xor eax, eax
mov byte [rbp + 0x1f], r12b
mov qword [rbp + 0x20], rax
lea r8, [0x140085bb0]
mov byte [rbp + 0x28], al
xor ecx, ecx
lea rax, [rbp - 1]
mov dword [rbp - 1], 0xa
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0x1f]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r12
call qword [sym.imp.POWRPROF.dll_PowerReadDCValue]
test eax, eax
jne 0x14003311d
mov qword [rsp + 0x80], r15
cmp byte [rsi + 0x108], r12b
je 0x140032f55
cmp dword [rsi + 0x100], 1
jne 0x140032f55
movzx eax, byte [rbp + 0x1f]
cmp dword [rsi + 0x104], eax
jg 0x140032f55
mov r15b, 1
jmp 0x140032f58
xor r15b, r15b
mov rcx, qword [rsi + 0xf0]
lea rax, [rbp + 3]
mov qword [rsp + 0x28], rax
lea r9, [rbp + 7]
lea rax, [rbp - 5]
mov dword [rbp - 5], r12d
xor r8d, r8d
mov qword [rsp + 0x20], rax
lea rdx, str.BatterySaveModeByPass
mov dword [rbp + 7], r12d
mov dword [rbp + 3], 4
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov eax, r12d
movzx ecx, r15b
cmp dword [rbp - 5], eax
sete al
cmp ecx, eax
jne 0x140033115
mov dword [rbp - 5], ecx
lea rax, [rbp - 5]
mov rcx, qword [rsi + 0xf0]
lea rdx, str.BatterySaveModeByPass
mov dword [rsp + 0x28], 4
mov r9d, 4
xor r8d, r8d
mov qword [rsp + 0x20], rax
mov qword [rsp + 0xb8], rbx
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov rax, qword [rsi + 0x130]
mov rbx, qword [rax]
cmp rbx, rax
je 0x14003310d
mov qword [rsp + 0xc0], rdi
mov qword [rsp + 0x88], r14
nop word [rax + rax]
mov rdi, qword [rbx + 0x10]
test rdi, rdi
je 0x1400330ed
movzx r14d, r15b
cmp dword [rbx + 0x18], r12d
jne 0x1400330c1
mov dword [rbp - 9], r12d
test r15b, r15b
je 0x140033081
or r8d, 0xffffffff
lea r9, [rbp - 9]
or edx, r8d
mov rcx, rdi
call qword [sym.imp.MaxxAudioAPOShell64.dll_WavesFX_Preset_GetType]
mov eax, dword [rbp - 9]
lea rdx, str.BatterySaveModeRecovery
mov rcx, qword [rsi + 0xf0]
and eax, 1
mov dword [rbp + 0xb], eax
mov r9d, 4
lea rax, [rbp + 0xb]
mov dword [rsp + 0x28], 4
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
jmp 0x1400330c1
mov rcx, qword [rsi + 0xf0]
lea rax, [rbp + 0xf]
mov qword [rsp + 0x28], rax
lea r9, [rbp + 0x13]
lea rax, [rbp - 9]
mov dword [rbp + 0x13], r12d
xor r8d, r8d
mov qword [rsp + 0x20], rax
lea rdx, str.BatterySaveModeRecovery
mov dword [rbp + 0xf], 4
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
cmp dword [rbp - 9], r12d
setne r14b
mov edx, 0xfffffffd
mov rcx, rdi
mov r8d, edx
test r14b, r14b
je 0x1400330dc
mov dword [rsp + 0x20], r12d
lea r9d, [rdx + 4]
jmp 0x1400330e7
mov dword [rsp + 0x20], 1
xor r9d, r9d
call qword [sym.imp.MaxxAudioAPOShell64.dll_WavesFX_Preset_SetTypeEx]
mov rbx, qword [rbx]
cmp rbx, qword [rsi + 0x130]
jne 0x140033010
mov r14, qword [rsp + 0x88]
mov rdi, qword [rsp + 0xc0]
mov rbx, qword [rsp + 0xb8]
mov r15, qword [rsp + 0x80]
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.14003a8a0
add rsp, 0x90
pop r12
pop rsi
pop rbp
ret