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

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rbp
push rsi
push rdi
push r12
sub rsp, 0xd0
mov rax, qword [0x00065100]
xor rax, rsp
mov qword [rsp + 0xc8], rax
xor r12d, r12d
mov rdi, rcx
lea rcx, [r11 - 0x68]
lea r8d, [r12 + 0x28]
xor edx, edx
mov qword [rsp + 0x48], r12
mov dword [r11 - 0x70], r12d
call fcn.000554c0
xor eax, eax
lea rdx, [0x0007e880]
lea rcx, [rsp + 0xa8]
mov rbx, r12
mov word [rsp + 0x50], r12w
mov qword [rsp + 0x52], rax
mov dword [rsp + 0x5a], eax
mov word [rsp + 0x5e], ax
mov dword [rsp + 0xb8], r12d
mov dword [rsp + 0xbc], eax
mov dword [rsp + 0xc0], eax
mov dword [rsp + 0xc4], eax
mov qword [rsp + 0x60], rbx
mov dword [rsp + 0x44], r12d
mov dword [rsp + 0x40], r12d
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea rdx, [0x0007e4f8]
lea rcx, [rsp + 0x68]
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
cmp rdi, r12
je 0x1681c
cmp qword [rdi + 8], r12
je 0x1681c
cmp word [rdi + 2], 0x4c
jb 0x1681c
mov rcx, rdi
call fcn.000164f0
lea rax, [rsp + 0xa8]
lea r8, [rsp + 0x78]
mov qword [rsp + 0x88], rax
lea rax, [rsp + 0x40]
lea rcx, [rsp + 0x48]
mov qword [rsp + 0x30], rax
xor r9d, r9d
mov edx, 0xf003f
mov dword [rsp + 0x28], r12d
mov dword [rsp + 0x78], 0x30
mov qword [rsp + 0x80], r12
mov qword [rsp + 0x20], r12
mov dword [rsp + 0x90], 0x40
mov qword [rsp + 0x98], r12
mov qword [rsp + 0xa0], r12
call qword [sym.imp.ntoskrnl.exe_ZwCreateKey]
cmp eax, r12d
mov esi, eax
jl 0x16786
cmp dword [rsp + 0x40], 1
je 0x16786
mov rbp, qword [rsp + 0x48]
lea rax, [rsp + 0x44]
lea r8d, [r12 + 2]
mov qword [rsp + 0x28], rax
lea rdx, [rsp + 0x68]
xor r9d, r9d
mov rcx, rbp
mov dword [rsp + 0x20], r12d
call qword [sym.imp.ntoskrnl.exe_ZwQueryValueKey]
cmp eax, 0xc0000034
je 0x16786
lea r9, [rsp + 0x44]
lea r8, [rsp + 0x60]
lea rdx, [rsp + 0x68]
mov rcx, rbp
mov dword [rsp + 0x20], eax
call fcn.0002aa2c
cmp al, r12b
je 0x16781
cmp dword [rsp + 0x40], 1
je 0x16781
mov rbx, qword [rsp + 0x60]
cmp rbx, r12
je 0x1680d
movzx eax, word [rdi + 2]
cmp dword [rbx + 8], eax
ja 0x167fd
mov r8d, dword [rbx + 8]
mov rcx, qword [rdi + 8]
lea rdx, [rbx + 0xc]
call fcn.000550e0
movzx r11d, word [rbx + 8]
mov word [rdi], r11w
jmp 0x167fd
mov rbx, qword [rsp + 0x60]
lea rcx, [rsp + 0xb8]
call qword [sym.imp.ntoskrnl.exe_ExUuidCreate]
cmp eax, r12d
mov esi, eax
jl 0x167f2
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0xb8]
call qword [sym.imp.ntoskrnl.exe_RtlStringFromGUID]
movzx r11d, word [rsp + 0x50]
mov rax, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x48]
mov dword [rsp + 0x28], r11d
lea rdx, [rsp + 0x68]
mov r9d, 1
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ntoskrnl.exe_ZwSetValueKey]
cmp eax, r12d
mov esi, eax
jl 0x167f2
lea rdx, [rsp + 0x50]
mov rcx, rdi
call fcn.000163a0
mov esi, eax
lea rcx, [rsp + 0x50]
call qword [sym.imp.ntoskrnl.exe_RtlFreeUnicodeString]
cmp rbx, r12
je 0x1680d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.ntoskrnl.exe_ExFreePoolWithTag]
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ntoskrnl.exe_ZwClose]
mov eax, esi
jmp 0x16821
mov eax, 0xc000000d
mov rcx, qword [rsp + 0xc8]
xor rcx, rsp
call fcn.00055060
lea r11, [rsp + 0xd0]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r12
pop rdi
pop rsi
ret