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

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rbp
mov qword [r11 + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x500
mov rax, qword [0x10002c180]
xor rax, rsp
mov qword [rsp + 0x4f0], rax
mov rax, qword [0x10002c100]
xor r14d, r14d
mov r13d, ecx
lea rcx, [0x10002c100]
mov qword [rsp + 0x68], r14
mov qword [rsp + 0x78], r14
mov qword [rsp + 0x70], r14
mov qword [r11 - 0x498], r14
mov ebp, r14d
mov dword [rsp + 0x40], r14d
call qword [rax + 0x18]
lea rdi, [rax + 0x18]
mov qword [rsp + 0x60], rdi
call fcn.10001744c
lea r9, [0x100013938]
mov r12b, al
lea rax, [rsp + 0x70]
lea r8d, [r14 + 0x17]
lea rcx, [0x1000138f8]
xor edx, edx
mov qword [rsp + 0x20], rax
call qword [sym.imp.ole32.dll_CoCreateInstance]
mov rcx, qword [rsp + 0x78]
cmp rcx, r14
je 0x100016a30
mov rdx, qword [rcx]
call qword [rdx + 0x10]
mov qword [rsp + 0x78], r14
mov rcx, qword [rsp + 0x70]
lea r9, [rsp + 0x78]
xor r8d, r8d
mov rax, qword [rcx]
xor edx, edx
call qword [rax + 0x20]
cmp eax, r14d
jne 0x100016a79
mov rcx, qword [rsp + 0x78]
lea rdx, [rsp + 0xd0]
mov r8d, 0x104
call fcn.1000172fc
lea rcx, [rsp + 0xd0]
xor edx, edx
mov r8d, 0x208
mov ebp, eax
call fcn.10001f020
mov rcx, qword [rsp + 0x68]
cmp rcx, r14
je 0x100016a8e
mov rdx, qword [rcx]
call qword [rdx + 0x10]
mov qword [rsp + 0x68], r14
lea r8, [rsp + 0x50]
lea rdx, [0x100013720]
mov r15d, 4
mov rcx, 0xffffffff80000002
mov qword [rsp + 0x50], r14
mov dword [rsp + 0x30], r14d
mov dword [rsp + 0x3c], r15d
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
mov rcx, qword [rsp + 0x50]
cmp rcx, r14
je 0x100016b69
lea rax, [rsp + 0x3c]
lea rdx, [0x100013750]
xor r9d, r9d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x30]
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, r14d
jne 0x100016b5e
cmp r12b, r14b
je 0x100016b11
cmp ebp, 0x50
jne 0x100016b25
cmp dword [rsp + 0x30], 2
je 0x100016b5e
mov dword [rsp + 0x30], 2
jmp 0x100016b34
mov eax, r13d
and eax, r15d
je 0x100016b20
cmp dword [rsp + 0x30], 2
jne 0x100016b07
cmp eax, r14d
jne 0x100016b5e
cmp dword [rsp + 0x30], 1
je 0x100016b5e
mov dword [rsp + 0x30], 1
mov eax, dword [rsp + 0x3c]
mov rcx, qword [rsp + 0x50]
lea rdx, [0x100013750]
mov dword [rsp + 0x28], eax
lea rax, [rsp + 0x30]
mov r9d, r15d
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rcx, qword [rsp + 0x70]
xor edx, edx
lea r9, [rsp + 0x90]
mov rax, qword [rcx]
lea r8d, [rdx + 1]
call qword [rax + 0x18]
cmp eax, r14d
jl 0x100016edf
mov rcx, qword [rsp + 0x90]
lea rdx, [rsp + 0x40]
mov rax, qword [rcx]
call qword [rax + 0x18]
cmp eax, r14d
jl 0x100016edf
mov esi, r14d
cmp dword [rsp + 0x40], r14d
jbe 0x100016edf
mov rcx, qword [rsp + 0x90]
lea r8, [rsp + 0x68]
mov edx, esi
mov rax, qword [rcx]
call qword [rax + 0x20]
mov rcx, qword [rsp + 0x68]
lea rdx, [rsp + 0xd0]
mov r8d, 0x104
call fcn.1000172fc
lea rcx, [rsp + 0x2e0]
xor edx, edx
mov r8d, 0x104
mov edi, eax
call fcn.10001f020
lea r8, [0x100013720]
lea rcx, [rsp + 0x2e0]
or r9, 0xffffffffffffffff
mov edx, 0x104
call fcn.10001e1dc
lea r8, [rsp + 0xf2]
lea rcx, [rsp + 0x2e0]
mov edx, 0x104
call fcn.10001e2cc
mov qword [rsp + 0x48], r14
cmp edi, 0x10
je 0x100016c43
cmp edi, 0x50
jne 0x100016ece
lea r8, [rsp + 0x48]
lea rdx, [rsp + 0x2e0]
mov rcx, 0xffffffff80000002
mov dword [rsp + 0x34], r14d
mov dword [rsp + 0x38], r15d
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
mov rcx, qword [rsp + 0x48]
cmp rcx, r14
je 0x100016d14
lea rax, [rsp + 0x38]
lea rdx, [0x100013750]
xor r9d, r9d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x34]
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, r14d
jne 0x100016d09
cmp r12b, r14b
je 0x100016cbc
cmp ebp, 0x50
jne 0x100016cd0
cmp dword [rsp + 0x34], 2
je 0x100016d09
mov dword [rsp + 0x34], 2
jmp 0x100016cdf
mov eax, r13d
and eax, r15d
je 0x100016ccb
cmp dword [rsp + 0x34], 2
jne 0x100016cb2
cmp eax, r14d
jne 0x100016d09
cmp dword [rsp + 0x34], 1
je 0x100016d09
mov dword [rsp + 0x34], 1
mov eax, dword [rsp + 0x38]
mov rcx, qword [rsp + 0x48]
lea rdx, [0x100013750]
mov dword [rsp + 0x28], eax
lea rax, [rsp + 0x34]
mov r9d, r15d
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rcx, qword [rsp + 0x68]
mov qword [rsp + 0x88], r14
cmp rcx, r14
je 0x100016ece
mov rax, qword [rcx]
lea rdx, [rsp + 0x88]
call qword [rax + 0x28]
cmp eax, r14d
jl 0x100016ece
mov rdx, qword [rsp + 0x88]
cmp rdx, r14
jne 0x100016d53
mov ecx, r14d
jmp 0x100016d65
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
dec rcx
mov r8d, ecx
lea rcx, [rsp + 0x60]
call fcn.100018528
mov rcx, qword [rsp + 0x88]
cmp rcx, r14
je 0x100016d8d
call qword [sym.imp.ole32.dll_CoTaskMemFree]
mov qword [rsp + 0x88], r14
lea rcx, [rsp + 0x80]
mov dword [rsp + 0x58], r14d
mov qword [rsp + 0x80], r14
mov dil, r14b
mov ebx, r14d
call fcn.100016740
mov rcx, qword [rsp + 0x80]
cmp rcx, r14
je 0x100016dd4
lea rcx, [rsp + 0x80]
call fcn.100016580
mov rcx, qword [rsp + 0x80]
mov dil, al
jmp 0x100016dd9
mov ebx, 0x80004005
cmp rcx, r14
je 0x100016de4
mov rax, qword [rcx]
call qword [rax + 0x10]
cmp ebx, r14d
jl 0x100016ece
cmp r12b, r14b
jne 0x100016e8b
test r15b, r13b
jne 0x100016e8b
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0xc0]
call fcn.100017c0c
lea r8, [rsp + 0x58]
lea rdx, [0x100012a30]
mov rcx, rax
call fcn.100015eb4
cmp eax, r14d
jl 0x100016e49
cmp dword [rsp + 0x58], r14d
sete dl
cmp dl, dil
je 0x100016e65
mov qword [rsp + 0xa8], r14
lea rcx, [rsp + 0xa8]
jmp 0x100016e60
cmp dil, r14b
je 0x100016e65
mov qword [rsp + 0xa0], r14
xor edx, edx
lea rcx, [rsp + 0xa0]
call fcn.100016920
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0xb0]
call fcn.100017c0c
lea rdx, [0x100012a48]
xor r8d, r8d
mov rcx, rax
call fcn.100015fa0
jmp 0x100016ece
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0xb8]
call fcn.100017c0c
lea rdx, [0x100012a48]
mov r8d, 1
mov rcx, rax
call fcn.100015fa0
cmp dil, r14b
je 0x100016ece
lea rcx, [rsp + 0x98]
xor edx, edx
mov qword [rsp + 0x98], r14
call fcn.100016920
inc esi
cmp esi, dword [rsp + 0x40]
jb 0x100016bb5
mov rdi, qword [rsp + 0x60]
mov rcx, qword [rsp + 0x70]
cmp rcx, r14
je 0x100016ef4
mov rax, qword [rcx]
call qword [rax + 0x10]
mov qword [rsp + 0x70], r14
lea rdx, [rdi - 0x18]
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
dec eax
cmp eax, r14d
jg 0x100016f10
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
xor eax, eax
mov rcx, qword [rsp + 0x4f0]
xor rcx, rsp
call fcn.10001dd30
lea r11, [rsp + 0x500]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret