Function at 0x140050a90
Capabilities:
Query or enumerate registry value

Disassembly:
mov rax, rsp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x60
mov qword [rax - 0x50], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov rbx, r9
mov rdi, r8
mov r15, rdx
mov r14, rcx
mov r11d, dword [0x1401ddd80]
lea r10d, [r11 + 2]
lea eax, [r11 + 1]
imul r10d, eax
imul r10d, r11d
mov eax, 0x2aaaaaab
imul r10d
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*2]
shl eax, 2
sub r10d, eax
cmp r10d, 0xb
jne 0x140050b01
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetFileType]
mov r11d, dword [0x1401ddd80]
xor r12d, r12d
mov esi, r12d
mov qword [rsp + 0x40], r12
mov dword [rsp + 0x48], r12d
mov qword [rsp + 0x50], r12
lea ecx, [r11 + 1]
imul ecx, r11d
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*2]
shl eax, 3
sub ecx, eax
cmp ecx, 0x17
jne 0x140050b85
movabs rax, 0x6263543747316b
mov qword [rsp + 0xa0], rax
lea rax, [rsp + 0xa0]
or r8, 0xffffffffffffffff
mov rcx, r8
nop dword [rax]
inc rcx
cmp byte [rax + rcx], 0
jne 0x140050b60
mov eax, 4
mul rcx
cmovo rax, r8
mov rcx, rax
call fcn.1400d68e8
mov rcx, rax
call fcn.1400d834c
mov qword [rsp + 0xa0], r12
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x20], rax
mov r9d, 0x2001f
xor r8d, r8d
mov rdx, qword [rdi]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140050df3
mov dword [rsp + 0x48], r12d
mov rsi, qword [rsp + 0xa0]
mov qword [rsp + 0x40], rsi
mov r8d, dword [0x1401ddd80]
mov ecx, r8d
imul ecx, r8d
mov eax, 0x2e8ba2e9
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x16
sub ecx, edx
cmp ecx, 6
jne 0x140050c1d
mov r9d, r12d
test r8d, r8d
je 0x140050c16
nop word [rax + rax]
mov ecx, r8d
and ecx, 1
add r9d, ecx
mov eax, r8d
cdq
sub eax, edx
sar eax, 1
mov r8d, eax
jne 0x140050c00
mov dword [0x1401ddd80], r9d
mov rax, qword [r14]
mov ecx, 1
sub ecx, dword [rax - 8]
mov eax, dword [rax - 0xc]
sub eax, 0x800
or eax, ecx
jge 0x140050c41
mov edx, 0x800
mov rcx, r14
call fcn.140002860
mov rbx, qword [r14]
cmp dword [rbx - 0xc], 0x800
jge 0x140050c58
mov ecx, 0x80070057
call fcn.140001920
int3
mov dword [rbx - 0x10], 0x800
mov rax, qword [r14]
mov word [rax + 0x1000], r12w
mov dword [rsp + 0xa0], 0x1000
mov edi, r12d
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x30]
xor r8d, r8d
mov rdx, qword [r15]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ebp, eax
test eax, eax
jne 0x140050ce9
mov eax, dword [rsp + 0x30]
dec eax
cmp eax, 1
jbe 0x140050cb6
mov ebp, 0xd
jmp 0x140050ce9
mov ecx, dword [rsp + 0xa0]
test rbx, rbx
je 0x140050ce2
test ecx, ecx
je 0x140050cde
test cl, 1
jne 0x140050cd7
mov eax, ecx
shr rax, 1
cmp word [rbx + rax*2 - 2], di
je 0x140050ce2
mov ebp, 0xd
jmp 0x140050ce9
mov word [rbx], r12w
mov edi, ecx
shr edi, 1
mov ebp, r12d
lea eax, [rdi - 1]
cmp eax, 0xffffffff
jne 0x140050d07
mov rcx, qword [r14]
test rcx, rcx
jne 0x140050cfe
mov eax, r12d
jmp 0x140050d0f
movsxd rdx, dword [rcx - 0xc]
call fcn.1400d7e8c
test eax, eax
js 0x140050de8
mov rcx, qword [r14]
cmp eax, dword [rcx - 0xc]
jg 0x140050de8
mov dword [rcx - 0x10], eax
movsxd rcx, eax
mov rax, qword [r14]
mov word [rax + rcx*2], r12w
mov ecx, dword [0x1401ddd80]
lea r8d, [rcx + 1]
imul r8d, ecx
mov eax, 0x66666667
imul r8d
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*4]
add eax, eax
sub r8d, eax
cmp r8d, 8
jne 0x140050dc6
test ecx, ecx
je 0x140050dc6
nop dword [rax + rax]
mov eax, ecx
and eax, 0x80000001
jge 0x140050d70
dec eax
or eax, 0xfffffffe
inc eax
test eax, eax
jne 0x140050d85
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
mov ecx, eax
mov dword [0x1401ddd80], eax
jmp 0x140050d92
lea ecx, [rcx*2 + 1]
mov dword [0x1401ddd80], ecx
mov eax, 0x55555556
imul ecx
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*2]
mov edx, ecx
sub edx, eax
je 0x140050db4
sub edx, 2
je 0x140050db7
dec edx
je 0x140050db9
jmp 0x140050dc2
add ecx, 2
inc ecx
add ecx, 2
mov dword [0x1401ddd80], ecx
test ecx, ecx
jne 0x140050d60
test rsi, rsi
je 0x140050ddc
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rsi, r12
mov qword [rsp + 0x40], r12
mov dword [rsp + 0x48], r12d
test ebp, ebp
sete bl
jmp 0x140050e27
mov ecx, 0x80070057
call fcn.140001920
int3
mov r8d, dword [0x1401ddd80]
imul r8d, r8d
mov eax, 0xb21642c9
imul r8d
add edx, r8d
sar edx, 4
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x17
sub r8d, edx
cmp r8d, 0x15
jne 0x140050e25
inc dword [0x1401df164]
xor bl, bl
test rsi, rsi
je 0x140050e3a
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rsp + 0x40], r12
mov dword [rsp + 0x48], r12d
movzx eax, bl
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret