Function at 0x140012ef0
Capabilities:
Query or enumerate registry key

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
lea rbp, [rsp - 0x37]
sub rsp, 0xc0
mov qword [rbp + 0x2f], 0xfffffffffffffffe
mov qword [rsp + 0xf0], rbx
mov r12, rcx
xor r13d, r13d
mov dword [rbp + 0x6f], r13d
lea rcx, str._h_r_
mov rax, qword [str._h_r_]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rbp - 0x21], rax
lea rcx, str._h_r_
mov rax, qword [str._h_r_]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rbp - 0x31], rax
lea rdx, [rbp - 0x31]
lea rcx, [rbp - 0x21]
call fcn.1400a7720
test al, al
jne 0x140012fb7
lea rdx, [0x140117ea0]
mov rcx, r12
call fcn.14000fdc0
nop
mov rdx, qword [rbp - 0x31]
add rdx, 0xffffffffffffffe8
or ebx, 0xffffffff
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140012f93
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x21]
add rdx, 0xffffffffffffffe8
lock xadd dword [rdx + 0x10], ebx
dec ebx
test ebx, ebx
jg 0x140012faf
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rax, r12
jmp 0x140013574
lea rcx, str._h_r_
mov rax, qword [str._h_r_]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
lea rbx, [rax + 0x18]
mov qword [rbp - 0x29], rbx
lea rdx, str.SOFTWAREMicrosoftWindows_NTCurrentVersionProfileList
test rdx, 0xffffffffffff0000
jne 0x140013002
movzx edi, dx
xor edx, edx
mov ecx, edi
call fcn.140001110
test rax, rax
je 0x140013015
mov r8d, edi
mov rdx, rax
lea rcx, [rbp - 0x29]
call fcn.140004fb0
jmp 0x140013011
mov r8d, 0x38
lea rcx, [rbp - 0x29]
call fcn.14000c510
mov rbx, qword [rbp - 0x29]
mov qword [rbp - 9], r13
mov dword [rbp - 1], r13d
mov qword [rbp + 7], r13
mov r9d, 0x20019
mov r8, rbx
mov rdx, 0xffffffff80000002
lea rcx, [rbp - 9]
call fcn.140002190
test eax, eax
je 0x1400130a0
lea rdx, [0x140117ea0]
mov rcx, r12
call fcn.14000fdc0
nop
mov rcx, qword [rbp - 9]
test rcx, rcx
je 0x14001305e
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
lea rdx, [rbx - 0x18]
or ebx, 0xffffffff
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x14001307c
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x31]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x14001309b
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
jmp 0x140012f93
mov esi, r13d
lea rcx, str._h_r_
mov rax, qword [str._h_r_]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rbp - 0x49], rax
mov edx, 0x104
mov dword [rbp + 0x6f], edx
or ebx, 0xffffffff
test edx, edx
js 0x140013569
mov rax, qword [rbp - 0x49]
mov ecx, 1
sub ecx, dword [rax - 8]
mov eax, dword [rax - 0xc]
sub eax, edx
or eax, ecx
jge 0x1400130ed
lea rcx, [rbp - 0x49]
call fcn.140001b30
lea rax, [rbp + 0x27]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], r13
mov qword [rsp + 0x28], r13
mov qword [rsp + 0x20], r13
lea r9, [rbp + 0x6f]
mov r8, qword [rbp - 0x49]
mov edx, esi
mov rcx, qword [rbp - 9]
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
inc esi
test eax, eax
jne 0x140013124
mov dil, 1
jmp 0x140013127
xor dil, dil
mov rcx, qword [rbp - 0x49]
movsxd rdx, dword [rcx - 0xc]
call qword [sym.imp.MSVCR100.dll_wcsnlen]
test eax, eax
js 0x14001355e
mov rcx, qword [rbp - 0x49]
cmp eax, dword [rcx - 0xc]
jg 0x14001355e
mov dword [rcx - 0x10], eax
movsxd rcx, eax
mov rax, qword [rbp - 0x49]
mov word [rax + rcx*2], r13w
test dil, dil
je 0x1400134dc
mov dword [rbp + 0x6f], 0x104
mov qword [rbp - 0x19], r13
lea rdx, [rbp - 0x19]
mov rcx, qword [rbp - 0x49]
call sub.ADVAPI32.dll_ConvertStringSidToSidW
cmp qword [rbp - 0x19], 0
jne 0x140013189
mov edx, dword [rbp + 0x6f]
jmp 0x1400130c7
lea rcx, str._h_r_
mov rax, qword [str._h_r_]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rbp - 0x41], rax
lea rcx, str._h_r_
mov rax, qword [str._h_r_]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rbp - 0x39], rax
mov dword [rbp + 0x7f], r13d
mov dword [rbp + 0x77], r13d
lea rax, [rbp - 0x11]
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0x77]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r13
lea r9, [rbp + 0x7f]
xor r8d, r8d
mov rdx, qword [rbp - 0x19]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupAccountSidW]
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x1400132f6
lea rax, [rbp - 0x39]
mov qword [rbp + 0xf], rax
mov qword [rbp + 0x17], r13
mov dword [rbp + 0x1f], ebx
mov edx, dword [rbp + 0x77]
test edx, edx
js 0x1400133f6
mov rdi, qword [rbp - 0x39]
mov ecx, 1
sub ecx, dword [rdi - 8]
mov eax, dword [rdi - 0xc]
sub eax, edx
or eax, ecx
jge 0x140013238
lea rcx, [rbp - 0x39]
call fcn.140001b30
mov rdi, qword [rbp - 0x39]
mov qword [rbp + 0x17], rdi
mov edx, dword [rbp + 0x7f]
test edx, edx
js 0x1400133eb
mov r8, qword [rbp - 0x41]
mov ecx, 1
sub ecx, dword [r8 - 8]
mov eax, dword [r8 - 0xc]
sub eax, edx
or eax, ecx
jge 0x14001326b
lea rcx, [rbp - 0x41]
call fcn.140001b30
mov r8, qword [rbp - 0x41]
lea rax, [rbp - 0x11]
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0x77]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdi
lea r9, [rbp + 0x7f]
mov rdx, qword [rbp - 0x19]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupAccountSidW]
mov rcx, qword [rbp - 0x41]
movsxd rdx, dword [rcx - 0xc]
call qword [sym.imp.MSVCR100.dll_wcsnlen]
test eax, eax
js 0x1400133e0
mov rcx, qword [rbp - 0x41]
cmp eax, dword [rcx - 0xc]
jg 0x1400133e0
mov dword [rcx - 0x10], eax
movsxd rcx, eax
mov rax, qword [rbp - 0x41]
mov word [rax + rcx*2], r13w
mov rcx, qword [rbp - 0x39]
movsxd rdx, dword [rcx - 0xc]
call qword [sym.imp.MSVCR100.dll_wcsnlen]
test eax, eax
js 0x1400133d5
mov rcx, qword [rbp - 0x39]
cmp eax, dword [rcx - 0xc]
jg 0x1400133d5
mov dword [rcx - 0x10], eax
movsxd rcx, eax
mov rax, qword [rbp - 0x39]
mov word [rax + rcx*2], r13w
mov rcx, qword [rbp - 0x19]
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov r11d, r13d
mov rax, qword [rbp - 0x41]
test rax, rax
setne r11b
test r11d, r11d
je 0x1400134d1
mov rcx, qword [rbp - 0x31]
sub rax, rcx
nop
movzx edx, word [rcx]
cmp dx, word [rcx + rax]
jne 0x140013337
add rcx, 2
test dx, dx
jne 0x140013320
mov eax, r13d
jmp 0x14001333c
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
sete al
mov rcx, qword [rbp - 0x39]
test al, al
je 0x14001338c
mov edx, r13d
mov rax, qword [rbp - 0x21]
test rax, rax
setne dl
test edx, edx
je 0x1400134c6
mov rdx, rcx
sub rax, rcx
movzx r8d, word [rdx]
cmp r8w, word [rdx + rax]
jne 0x14001337e
add rdx, 2
test r8w, r8w
jne 0x140013364
mov eax, r13d
jmp 0x140013383
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
sete al
test al, al
jne 0x140013401
lea rdx, [rcx - 0x18]
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x1400133a7
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x41]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jle 0x1400133c4
mov edx, dword [rbp + 0x6f]
jmp 0x1400130c7
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov edx, dword [rbp + 0x6f]
jmp 0x1400130c7
mov ecx, 0x80070057
call fcn.140001000
nop
mov ecx, 0x80070057
call fcn.140001000
int3
mov ecx, 0x80070057
call fcn.140001000
nop
mov ecx, 0x80070057
call fcn.140001000
int3
mov rcx, qword [rbp - 0x49]
add rcx, 0xffffffffffffffe8
call fcn.140001b90
add rax, 0x18
mov qword [r12], rax
mov rdx, qword [rbp - 0x39]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140013435
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x41]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140013454
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x49]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140013473
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rcx, qword [rbp - 9]
test rcx, rcx
je 0x140013483
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rdx, qword [rbp - 0x29]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x1400134a2
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x31]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x1400134c1
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
jmp 0x140012f93
mov ecx, 0x80004005
call fcn.140001000
int3
mov ecx, 0x80004005
call fcn.140001000
nop
lea rdx, [0x140117ea0]
mov rcx, r12
call fcn.14000fdc0
nop
mov rdx, qword [rbp - 0x49]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x14001350b
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rcx, qword [rbp - 9]
test rcx, rcx
je 0x14001351b
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rdx, qword [rbp - 0x29]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x14001353a
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x31]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140013559
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
jmp 0x140012f93
mov ecx, 0x80070057
call fcn.140001000
int3
mov ecx, 0x80070057
call fcn.140001000
nop
mov rbx, qword [rsp + 0xf0]
add rsp, 0xc0
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret