Function at 0x140004d18
Capabilities:
Query or enumerate registry value

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rsi
mov qword [r11 + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x50
xor r13d, r13d
mov r15, r9
mov qword [rbp - 0x10], r13
mov r12, r8
mov qword [rbp - 8], r13
mov r14, rdx
mov qword [rbp - 0x18], r13
mov esi, r13d
mov dword [rbp + 0x30], r13d
mov edi, r13d
test rcx, rcx
je 0x140005081
cmp word [rcx], r13w
je 0x140005081
test rdx, rdx
je 0x140005081
cmp word [rdx], r13w
je 0x140005081
test r8, r8
je 0x140005081
test r9, r9
je 0x140005081
mov qword [r8], r13
lea rax, [rbp - 0x10]
mov qword [r9], r13
mov rdx, rcx
mov r9d, 0x20019
mov qword [r11 - 0x58], rax
xor r8d, r8d
mov rcx, 0xffffffff80000000
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x14000501a
mov rdx, qword [str.shell]
lea rax, [rbp - 8]
mov rcx, qword [rbp - 0x10]
mov r9d, 0x20019
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x14000501a
mov rcx, qword [rbp - 8]
lea rax, [rbp - 0x18]
mov r9d, 0x20019
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov rdx, r14
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x14000501a
mov rdx, qword [str.RedirectFileType]
lea rax, [rbp + 0x30]
mov rcx, qword [rbp - 0x18]
lea r9, [rbp - 0x20]
mov qword [rsp + 0x28], rax
xor r8d, r8d
mov qword [rsp + 0x20], r13
mov dword [rbp - 0x20], r13d
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx ebx, ax
mov r14d, r13d
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
cmovns r14d, dword [rbp - 0x20]
mov dword [rbp - 0x20], r14d
js 0x140004f01
lea eax, [r14 - 1]
cmp eax, 1
ja 0x140004f01
mov edx, dword [rbp + 0x30]
xor ecx, ecx
add rdx, 2
call qword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov rsi, rax
test rax, rax
jne 0x140004eae
mov ebx, 0x8007000e
jmp 0x14000501a
mov r8d, dword [rbp + 0x30]
xor edx, edx
add r8, 2
mov rcx, rax
call sub.VCRUNTIME140.dll_memset
mov rdx, qword [str.RedirectFileType]
lea rax, [rbp + 0x30]
mov rcx, qword [rbp - 0x18]
lea r8, [rbp - 0x20]
mov r9, rsi
mov qword [rsp + 0x20], rax
call fcn.140004094
mov ebx, eax
test eax, eax
js 0x140005000
mov r14d, dword [rbp - 0x20]
lea eax, [r14 - 1]
cmp eax, 1
jbe 0x140004f19
mov ebx, 0x8000ffff
jmp 0x140005000
mov ecx, 0x80000000
lea eax, [rbx + rcx]
test ecx, eax
jne 0x140004f19
cmp ebx, 0x80070002
jne 0x14000501a
mov rdx, qword [str.RedirectVerb]
lea rax, [rbp + 0x30]
mov rcx, qword [rbp - 0x18]
lea r9, [rbp - 0x20]
mov qword [rsp + 0x28], rax
xor r8d, r8d
mov qword [rsp + 0x20], r13
mov dword [rbp - 0x20], r13d
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
cmovns r14d, dword [rbp - 0x20]
mov dword [rbp - 0x20], r14d
js 0x140004fcc
lea eax, [r14 - 1]
cmp eax, 1
ja 0x140004fcc
mov edx, dword [rbp + 0x30]
xor ecx, ecx
add rdx, 2
call qword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov rdi, rax
test rax, rax
jne 0x140004f85
mov ebx, 0x8007000e
jmp 0x140005000
mov r8d, dword [rbp + 0x30]
xor edx, edx
add r8, 2
mov rcx, rax
call sub.VCRUNTIME140.dll_memset
mov rdx, qword [str.RedirectVerb]
lea rax, [rbp + 0x30]
mov rcx, qword [rbp - 0x18]
lea r8, [rbp - 0x20]
mov r9, rdi
mov qword [rsp + 0x20], rax
call fcn.140004094
mov ebx, eax
test eax, eax
js 0x140005000
mov eax, dword [rbp - 0x20]
dec eax
cmp eax, 1
jbe 0x140004fdd
jmp 0x140004ef7
cmp ebx, 0x80070002
jne 0x140004fd9
mov ebx, r13d
jmp 0x140004fdd
test ebx, ebx
js 0x140005000
test rsi, rsi
je 0x14000500d
cmp word [rsi], r13w
je 0x140005000
test rdi, rdi
je 0x140005000
cmp word [rdi], r13w
je 0x140005000
mov qword [r12], rsi
mov rsi, r13
mov qword [r15], rdi
mov rdi, r13
test rsi, rsi
je 0x14000500d
mov rcx, rsi
call fcn.140003310
test rdi, rdi
je 0x14000501a
mov rcx, rdi
call fcn.140003310
mov rcx, qword [rbp - 0x10]
test rcx, rcx
je 0x140005045
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
mov rax, qword [rbp - 0x10]
test ecx, ecx
cmovns rax, r13
mov qword [rbp - 0x10], rax
mov rcx, qword [rbp - 8]
test rcx, rcx
je 0x140005070
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
mov rax, qword [rbp - 8]
test ecx, ecx
cmovns rax, r13
mov qword [rbp - 8], rax
mov rcx, qword [rbp - 0x18]
test rcx, rcx
je 0x140005086
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x140005086
mov ebx, 0x80070057
lea r11, [rsp + 0x50]
mov eax, ebx
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret