Function at 0x18002131c
Capabilities:
Encrypt data using dpapi
Query or enumerate registry value

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xb8
mov rcx, qword [0x18002f7f8]
xor edx, edx
mov r8d, 0x208
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
test rax, rax
mov rbp, rax
jne 0x18002135e
lea eax, [rbp + 8]
jmp 0x1800217c4
mov rcx, qword [0x18002f7f8]
xor edx, edx
mov r8d, 0x1000
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
test rax, rax
mov rbx, rax
jne 0x180021383
lea edi, [rax + 8]
jmp 0x180021799
lea r13, [0x18002e118]
lea rsi, [0x18002e070]
mov r15d, 3
xor edx, edx
lea rcx, [rsp + 0x70]
lea r8d, [rdx + 0x34]
call sub.ntdll.dll_memset
mov r14, qword [r13]
mov rcx, qword [rsp + 0x100]
lea rax, [rsp + 0x110]
lea r9, [rsp + 0x40]
xor r12d, r12d
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x118]
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rax
and qword [rsp + 0x20], r12
mov r8, rbp
xor edx, edx
mov qword [rsp + 0x48], r14
mov dword [rsp + 0x40], 0x104
mov dword [rsp + 0x110], 0x1000
call qword [sym.imp.ADVAPI32.dll_RegEnumValueW]
cmp eax, 0x103
mov edi, eax
je 0x1800216b9
mov r14, qword [rsp + 0x100]
test edi, edi
jne 0x180021657
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x18002145a
cmp dword [rsp + 0x118], 3
jne 0x18002145a
mov edx, dword [rsp + 0x110]
mov rcx, rbx
call fcn.18002125c
mov qword [rsp + 0x70], rax
mov rcx, qword [rsi + 8]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi + 8]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x180021497
cmp dword [rsp + 0x118], 3
jne 0x180021497
mov edx, dword [rsp + 0x110]
mov rcx, rbx
call fcn.18002125c
mov qword [rsp + 0x78], rax
mov rcx, qword [rsi + 0x10]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi + 0x10]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x1800214d7
cmp dword [rsp + 0x118], 3
jne 0x1800214d7
mov edx, dword [rsp + 0x110]
mov rcx, rbx
call fcn.18002125c
mov qword [rsp + 0x80], rax
mov rcx, qword [rsi + 0x20]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi + 0x20]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x180021517
cmp dword [rsp + 0x118], 3
jne 0x180021517
mov edx, dword [rsp + 0x110]
mov rcx, rbx
call fcn.18002125c
mov qword [rsp + 0x88], rax
mov rcx, qword [rsi + 0x18]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi + 0x18]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x180021553
cmp dword [rsp + 0x110], 4
jne 0x180021553
cmp dword [rsp + 0x118], 4
jne 0x180021553
mov eax, dword [rbx]
mov dword [rsp + 0xa0], eax
mov rcx, qword [rsi + 0x28]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi + 0x28]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x180021605
cmp dword [rsp + 0x118], 3
jne 0x180021605
cmp byte [rbx], 2
jne 0x180021605
lea r8d, [rax + 0xc]
lea rcx, [rsp + 0x50]
xor edx, edx
call sub.ntdll.dll_memset
mov r11d, dword [rsp + 0x110]
lea rax, [rbx + 1]
mov qword [rsp + 0x64], rax
lea rax, [rsp + 0x50]
add r11d, 0xffffffff
mov qword [rsp + 0x30], rax
and dword [rsp + 0x28], 0
and qword [rsp + 0x20], 0
lea rcx, [rsp + 0x60]
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov dword [rsp + 0x60], r11d
call qword [sym.imp.CRYPT32.dll_CryptUnprotectData]
test eax, eax
je 0x1800215f5
mov edx, dword [rsp + 0x50]
mov rcx, qword [rsp + 0x54]
call fcn.18002125c
mov qword [rsp + 0x90], rax
mov rcx, qword [rsp + 0x54]
test rcx, rcx
je 0x180021605
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsi + 0x30]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rdx, qword [rsi + 0x30]
mov rcx, rbp
lea r8d, [rax + 1]
call qword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x180021657
cmp dword [rsp + 0x110], 4
jne 0x180021657
cmp dword [rsp + 0x118], 4
jne 0x180021657
cmp dword [rbx], eax
lea rcx, [0x18002a260]
jne 0x18002164a
lea rcx, [0x18002a264]
call fcn.1800212c0
mov qword [rsp + 0x98], rax
lea rax, [rsp + 0x110]
add r12d, 1
lea r9, [rsp + 0x40]
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x118]
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rax
and qword [rsp + 0x20], 0
mov r8, rbp
mov edx, r12d
mov rcx, r14
mov dword [rsp + 0x40], 0x104
mov dword [rsp + 0x110], 0x1000
call qword [sym.imp.ADVAPI32.dll_RegEnumValueW]
cmp eax, 0x103
mov edi, eax
jne 0x180021417
mov r14, qword [rsp + 0x48]
mov r8, qword [rsp + 0x70]
test r8, r8
je 0x1800216fe
cmp qword [rsp + 0x80], 0
je 0x1800216ea
mov rcx, qword [rsp + 0x108]
lea r8, [rsp + 0x70]
mov rdx, r14
call fcn.18001fba0
mov r8, qword [rsp + 0x70]
mov edi, eax
test r8, r8
je 0x1800216fe
mov rcx, qword [0x18002f7f8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r8, qword [rsp + 0x78]
test r8, r8
je 0x180021717
mov rcx, qword [0x18002f7f8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r8, qword [rsp + 0x90]
test r8, r8
je 0x180021733
mov rcx, qword [0x18002f7f8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r8, qword [rsp + 0x80]
test r8, r8
je 0x18002174f
mov rcx, qword [0x18002f7f8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r8, qword [rsp + 0x88]
test r8, r8
je 0x18002176b
mov rcx, qword [0x18002f7f8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r8, qword [rsp + 0x98]
test r8, r8
je 0x180021787
mov rcx, qword [0x18002f7f8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
add rsi, 0x38
add r13, 8
sub r15, 1
jne 0x180021397
mov rcx, qword [0x18002f7f8]
mov r8, rbp
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test rbx, rbx
je 0x1800217c2
mov rcx, qword [0x18002f7f8]
mov r8, rbx
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, edi
add rsp, 0xb8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret