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

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0x100
mov qword [rsp + 0x48], 0xfffffffffffffffe
mov qword [rax + 0x20], rbx
movaps xmmword [rax - 0x48], xmm6
mov rax, qword [0x1402f2080]
xor rax, rsp
mov qword [rbp + 0xf], rax
mov ebx, r8d
mov r15d, edx
mov r14, rcx
mov sil, 1
mov byte [rsp + 0x30], sil
xor r13b, r13b
xor eax, eax
mov qword [rbp - 0x49], rax
mov rax, qword [rcx + 0x470]
mov qword [rsp + 0x40], rax
mov dword [rbp - 0x49], 0xffffffff
mov qword [rbp - 0x41], rax
test rax, rax
je 0x1401218bf
mov edx, 0xbb8
mov rcx, rax
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_WaitForSingleObject]
mov dword [rbp - 0x49], eax
mov rcx, r14
call fcn.1401207c0
test r15d, r15d
jns 0x1401218d3
mov r15d, dword [r14 + 0x248]
cmp ebx, 0xffffffff
jne 0x1401218e3
mov ebx, dword [r14 + 0x24c]
mov edi, ebx
jmp 0x1401218ea
mov edi, dword [r14 + 0x24c]
mov rcx, r14
call fcn.140124140
xor r9d, r9d
mov r8d, edi
mov edx, r15d
lea rcx, [r14 + 0x140]
call fcn.1401144f0
mov rdi, rax
mov qword [rsp + 0x38], rax
xorps xmm0, xmm0
movdqu xmmword [rsp + 0x58], xmm0
call fcn.140016e40
mov qword [rsp + 0x58], rax
lea r9, [rsp + 0x58]
mov r8d, ebx
mov edx, r15d
lea rcx, [r14 + 0x140]
call fcn.140114ac0
xor r12d, r12d
mov rax, qword [rsp + 0x58]
mov rbx, qword [rax]
xorps xmm6, xmm6
cmp rbx, rax
je 0x140121bcf
xor r9d, r9d
mov r8d, dword [rbx + 0x1c]
mov edx, r15d
mov rcx, r14
call fcn.140123f20
mov rsi, rax
test rdi, rdi
je 0x140121b9b
test rax, rax
je 0x140121b9b
movsd qword [rsp + 0x50], xmm6
mov r8d, 2
lea rdx, str.Param_u
lea rcx, [rbp - 0x31]
call fcn.140126330
mov dword [rbp - 0x71], 8
lea rax, [rbp - 0x71]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
lea r9, [rbp - 0x39]
xor r8d, r8d
lea rdx, [rbp - 0x31]
mov rcx, qword [rsi + 8]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x1401219e2
mov rcx, qword [rsi + 0x10]
test rcx, rcx
je 0x1401219ec
lea r8, [rsp + 0x50]
mov edx, 2
call fcn.140111ed0
test al, al
je 0x1401219ec
ucomisd xmm6, qword [rsp + 0x50]
jp 0x1401219f1
jne 0x1401219f1
xor dil, dil
jmp 0x1401219f4
mov dil, 1
xor edx, edx
mov rcx, qword [rsi + 8]
call qword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
test dil, dil
je 0x140121a18
movsd xmm2, qword [rsp + 0x50]
mov edx, 2
mov rcx, rsi
call fcn.140125f90
mov r8d, dword [rbx + 0x1c]
mov edx, r15d
lea rcx, [r14 + 0x140]
call fcn.140114720
test eax, eax
je 0x140121a5d
mov dword [rbp - 0x69], eax
mov dword [rsp + 0x28], 4
lea rax, [rbp - 0x69]
mov qword [rsp + 0x20], rax
mov r9d, 4
xor r8d, r8d
lea rdx, str.Type
mov rcx, qword [rsi + 8]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegSetValueExW]
mov eax, dword [rbx + 0x1c]
mov rdi, qword [rsp + 0x38]
cmp dword [r14 + 0x24c], eax
jne 0x140121b6a
movzx eax, word [rdi + 0xd8]
and eax, 1
test al, al
je 0x140121b50
call fcn.140015450
mov rcx, rax
test rax, rax
je 0x140121c78
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp - 0x51], rax
mov r8d, r15d
lea rdx, str.SoundModeOnOutput_d
lea rcx, [rbp - 0x51]
call fcn.140021720
mov eax, dword [rbx + 0x1c]
mov dword [rbp - 0x61], eax
mov dword [rsp + 0x28], 4
lea rax, [rbp - 0x61]
mov qword [rsp + 0x20], rax
mov r9d, 4
xor r8d, r8d
mov rdi, qword [rbp - 0x51]
mov rdx, rdi
mov rcx, qword [r14 + 0x90]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegSetValueExW]
cmp r15d, dword [r14 + 0x248]
jne 0x140121b2f
mov eax, dword [rbx + 0x1c]
mov dword [r14 + 0x24c], eax
mov dword [rbp - 0x59], eax
mov dword [rsp + 0x28], 4
lea rax, [rbp - 0x59]
mov qword [rsp + 0x20], rax
mov r9d, 4
xor r8d, r8d
lea rdx, str.ActiveSoundMode
mov rcx, qword [r14 + 0x90]
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegSetValueExW]
nop
lea rdx, [rdi - 0x18]
mov eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140121b4b
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
mov rdi, qword [rsp + 0x38]
cmp r15d, dword [r14 + 0x248]
jne 0x140121b67
mov eax, dword [r14 + 0x24c]
cmp dword [rbx + 0x1c], eax
cmove r12, rsi
mov r13b, 1
movzx esi, byte [rsp + 0x30]
mov rax, qword [rbx + 0x10]
cmp byte [rax + 0x19], 0
je 0x140121ba5
mov rax, qword [rbx + 8]
cmp byte [rax + 0x19], 0
jne 0x140121b96
cmp rbx, qword [rax + 0x10]
jne 0x140121b96
mov rbx, rax
mov rax, qword [rax + 8]
cmp byte [rax + 0x19], 0
je 0x140121b83
mov rbx, rax
jmp 0x140121bc0
xor sil, sil
mov byte [rsp + 0x30], sil
jmp 0x140121b6f
mov rbx, rax
mov rcx, qword [rax]
cmp byte [rcx + 0x19], 0
jne 0x140121bc0
mov rbx, rcx
mov rax, qword [rcx]
mov rcx, rax
cmp byte [rax + 0x19], 0
je 0x140121bb1
test sil, sil
je 0x140121bcf
mov rax, qword [rsp + 0x58]
jmp 0x140121947
test r12, r12
je 0x140121bef
mov byte [rsp + 0x20], 1
mov r9d, 1
mov r8, r12
mov rdx, rdi
mov rcx, r14
call fcn.140124560
jmp 0x140121c12
test r13b, r13b
je 0x140121c12
mov byte [rsp + 0x28], 1
mov dword [rsp + 0x20], 1
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, r14
call fcn.140120270
nop
lea rcx, [rsp + 0x58]
call fcn.140016d80
mov edx, 0x20
mov rcx, qword [rsp + 0x58]
call fcn.140146bac
nop
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x140121c45
cmp dword [rbp - 0x49], 0x102
je 0x140121c45
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
movzx eax, sil
mov rcx, qword [rbp + 0xf]
xor rcx, rsp
call fcn.140146480
mov rbx, qword [rsp + 0x158]
movaps xmm6, xmmword [rsp + 0xf0]
add rsp, 0x100
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
mov ecx, 0x80004005
call fcn.1400151f0
int3