Function at 0x1400495e0
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov qword [rsp + 0x10], rdx
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1f]
sub rsp, 0xf8
mov rbx, rdx
xor dil, dil
mov byte [rbp + 0x67], dil
xor r14d, r14d
mov qword [rbp - 0x21], r14
mov dword [rbp - 0x19], r14d
mov qword [rbp - 0x11], r14
mov qword [rbp - 1], r14
mov dword [rbp + 7], r14d
mov qword [rbp + 0xf], r14
mov qword [rbp - 0x79], r14
lea rax, [rbp - 0x79]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
mov rdx, qword [rdx]
mov rcx, qword [rcx]
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea r15, [r14 - 1]
test eax, eax
jne 0x140049aad
mov rsi, qword [rbp - 0x79]
mov qword [rbp - 0x21], rsi
mov dword [rbp - 0x19], r14d
mov r12d, r14d
mov dword [rbp + 0x77], r14d
mov ecx, 0x202
call fcn.140003f10
mov r13, rax
mov qword [rbp - 0x59], rax
mov dword [rsp + 0x44], 0x100
nop dword [rax]
lea rax, [rbp - 9]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], r14
mov qword [rsp + 0x28], r14
mov qword [rsp + 0x20], r14
lea r9, [rsp + 0x44]
mov r8, r13
mov edx, r12d
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x140049a84
mov rbx, r14
mov qword [rbp - 0x39], rbx
mov dword [rbp - 0x31], r14d
mov qword [rbp - 0x29], r14
mov qword [rsp + 0x58], r14
lea rax, [rsp + 0x58]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
mov rdx, r13
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140049a5e
mov rdi, qword [rsp + 0x58]
mov rbx, rdi
mov qword [rbp - 0x39], rbx
mov dword [rbp - 0x31], r14d
mov ecx, 0x202
call fcn.140003f10
mov r13, rax
mov dword [rbp + 0x7f], 0x200
lea rax, [rbp + 0x7f]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r13
lea r9, [rbp - 0x71]
xor r8d, r8d
lea rdx, str.service
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x140049a34
mov eax, dword [rbp - 0x71]
dec eax
cmp eax, 1
ja 0x140049a34
mov ecx, dword [rbp + 0x7f]
test r13, r13
je 0x14004977b
test ecx, ecx
je 0x140049776
test cl, 1
jne 0x140049a39
mov eax, ecx
shr rax, 1
cmp word [r13 + rax*2 - 2], 0
je 0x14004977b
jmp 0x140049a39
mov word [r13], r14w
shr ecx, 1
mov word [r13 + rcx*2], r14w
call fcn.1400102e4
mov rcx, rax
test rax, rax
je 0x140049af1
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp - 0x61], rax
mov r8, r13
lea rdx, str.systemcurrentcontrolset_services_senum
lea rcx, [rbp - 0x61]
call fcn.140044a30
mov rbx, r14
mov qword [rbp - 0x51], rbx
mov dword [rbp - 0x49], r14d
mov qword [rbp - 0x41], r14
mov qword [rsp + 0x50], r14
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
mov rdx, qword [rbp - 0x61]
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x1400499fa
mov rsi, qword [rsp + 0x50]
mov qword [rbp - 0x51], rsi
mov dword [rbp - 0x49], r14d
mov r12d, r14d
call fcn.1400102e4
mov rcx, rax
test rax, rax
je 0x140049b07
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rsp + 0x48], rax
xor r8d, r8d
lea rdx, [0x1402cfba4]
lea rcx, [rsp + 0x48]
call fcn.140044a30
mov ecx, 0x202
call fcn.140003f10
mov rdi, rax
nop word [rax + rax]
mov dword [rsp + 0x40], 0x200
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdi
lea r9, [rbp - 0x6d]
xor r8d, r8d
mov rbx, qword [rsp + 0x48]
mov rdx, rbx
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x1400499b5
mov eax, dword [rbp - 0x6d]
dec eax
cmp eax, 1
ja 0x1400499b5
mov ecx, dword [rsp + 0x40]
test rdi, rdi
je 0x1400498c2
test ecx, ecx
je 0x1400498be
test cl, 1
jne 0x1400499b5
mov eax, ecx
shr rax, 1
cmp word [rdi + rax*2 - 2], 0
jne 0x1400499b5
jmp 0x1400498c2
mov word [rdi], r14w
shr ecx, 1
mov word [rdi + rcx*2], r14w
call fcn.1400102e4
test rax, rax
je 0x140049afc
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
add rax, 0x18
mov qword [rbp - 0x69], rax
test rdi, rdi
je 0x14004991d
cmp rdi, 0x10000
jae 0x140049904
movzx edx, di
lea rcx, [rbp - 0x69]
call fcn.140010b40
jmp 0x14004992d
mov r8, r15
nop word [rax + rax]
inc r8
cmp word [rdi + r8*2], 0
jne 0x140049910
jmp 0x140049920
mov r8d, r14d
mov rdx, rdi
lea rcx, [rbp - 0x69]
call fcn.140002b2c
nop
mov rax, qword [rbp + 0x6f]
mov rdx, qword [rax]
mov rbx, qword [rbp - 0x69]
test rdx, rdx
jne 0x140049942
mov esi, r15d
jmp 0x140049968
cmp dword [rbx - 0x10], 0
jge 0x14004994d
mov esi, r15d
jmp 0x140049968
mov rcx, rbx
call fcn.140225168
mov rsi, rax
test rax, rax
jne 0x140049962
mov esi, r15d
jmp 0x140049968
sub rsi, rbx
sar rsi, 1
lea rdx, [rbx - 0x18]
mov eax, r15d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140049982
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
test esi, esi
jns 0x1400499a7
inc r12d
mov r8d, r12d
lea rdx, [0x1402cfba4]
lea rcx, [rsp + 0x48]
call fcn.140044a30
mov rsi, qword [rsp + 0x50]
jmp 0x140049850
mov byte [rbp + 0x67], 1
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
test rdi, rdi
je 0x1400499c2
mov rcx, rdi
call fcn.1400041d4
test rsi, rsi
je 0x1400499d4
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rbp - 0x51], r14
mov dword [rbp - 0x49], r14d
lea rdx, [rbx - 0x18]
mov eax, r15d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400499f2
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov r12d, dword [rbp + 0x77]
mov rbx, qword [rbp - 0x51]
test rbx, rbx
je 0x140049a09
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rdx, qword [rbp - 0x61]
add rdx, 0xffffffffffffffe8
mov eax, r15d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140049a27
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rsi, qword [rbp - 0x79]
mov rdi, qword [rsp + 0x58]
mov rbx, qword [rbp - 0x39]
test r13, r13
je 0x140049a41
mov rcx, r13
call fcn.1400041d4
test rdi, rdi
je 0x140049a56
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rbx, r14
mov qword [rbp - 0x39], rbx
mov r13, qword [rbp - 0x59]
movzx edi, byte [rbp + 0x67]
inc r12d
mov dword [rbp + 0x77], r12d
mov dword [rsp + 0x44], 0x100
test rbx, rbx
je 0x140049a7b
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
test dil, dil
je 0x140049680
test r13, r13
je 0x140049a91
mov rcx, r13
call fcn.1400041d4
test rsi, rsi
je 0x140049aa5
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rbp - 0x21], r14
jmp 0x140049aa9
mov r14, qword [rbp - 0x21]
mov rbx, qword [rbp + 0x6f]
test r14, r14
je 0x140049abc
mov rcx, r14
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rdx, qword [rbx]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], r15d
sub r15d, 1
jg 0x140049ad9
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [rreloc.OLEAUT32.dll_VariantClear + 8]
movzx eax, dil
add rsp, 0xf8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret
mov ecx, 0x80004005
call fcn.140002dfc
nop
mov ecx, 0x80004005
call fcn.140002dfc
nop
mov ecx, 0x80004005
call fcn.140002dfc
int3