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

Disassembly:
push rsi
push rdi
push r12
mov eax, 0x1060
call fcn.140050c50
sub rsp, rax
mov qword [rsp + 0x68], 0xfffffffffffffffe
mov qword [rsp + 0x1090], rbx
mov qword [rsp + 0x1098], rbp
mov rax, qword [0x140074c00]
xor rax, rsp
mov qword [rsp + 0x1050], rax
mov rbp, rdx
mov rbx, rcx
test rcx, rcx
je 0x140007fc1
xor eax, eax
or rsi, 0xffffffffffffffff
mov rcx, rsi
mov rdi, rbx
repne scasw ax, word [rdi]
not rcx
cmp rcx, 1
je 0x140007fc1
lea rcx, [rsp + 0xb0]
lea rdx, str.SYSTEMCurrentControlSetEnumSWDPRINTENUM
lea r8d, [rax + 0x58]
call fcn.14003f7f0
lea rcx, [rsp + 0x110]
lea rdx, str.SYSTEMCurrentControlSetEnumSWDDAFWSDProvider
lea r8d, [rsi + 0x63]
call fcn.14003f7f0
xor r12d, r12d
mov qword [rsp + 0x38], r12
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, [rsp + 0xb0]
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x140007937
lea rdx, [rsp + 0xb0]
lea rcx, str.GetWSDUrlAddressC_not_found_reg___s__exit
call fcn.140005be0
xor eax, eax
jmp 0x140007fc3
mov word [rsp + 0x850], r12w
xor edx, edx
mov r8d, 0x7fe
lea rcx, [rsp + 0x852]
call fcn.14003ea70
mov edi, r12d
mov word [rsp + 0x250], r12w
xor edx, edx
mov r8d, 0x1fe
lea rcx, [rsp + 0x252]
call fcn.14003ea70
mov dword [rsp + 0x44], pe_nt_image_headers64
mov dword [rsp + 0x40], r12d
mov r9d, 0x400
lea r8, [rsp + 0x850]
xor edx, edx
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
test eax, eax
jne 0x140007a66
nop word [rax + rax]
inc edi
mov rdx, rbx
lea rcx, [rsp + 0x850]
call fcn.14003e0b4
test rax, rax
je 0x140007a43
mov qword [rsp + 0x48], r12
lea rax, [rsp + 0x48]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, [rsp + 0x850]
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140007a43
mov dword [rsp + 0x44], pe_nt_image_headers64
mov dword [rsp + 0x40], r12d
lea rax, [rsp + 0x44]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x250]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x40]
xor r8d, r8d
lea rdx, str.ContainerID
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x140007a66
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov r9d, 0x400
lea r8, [rsp + 0x850]
mov edx, edi
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
test eax, eax
je 0x1400079b0
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
mov rcx, rsi
lea rdi, [rsp + 0x250]
repne scasw ax, word [rdi]
not rcx
cmp rcx, 1
je 0x140007fc3
lea rdx, [0x140060ce0]
lea rcx, [rsp + 0x250]
call fcn.14003e0b4
mov rdi, rax
lea rdx, [0x140060ce4]
lea rcx, [rsp + 0x250]
call fcn.14003e0b4
mov rbx, rax
mov word [rsp + 0x180], r12w
xor edx, edx
mov r8d, 0xc6
lea rcx, [rsp + 0x182]
call fcn.14003ea70
mov word [rsp + 0x450], r12w
xor edx, edx
mov r8d, 0x3fe
lea rcx, [rsp + 0x452]
call fcn.14003ea70
lea rdx, [rdi + 2]
xor eax, eax
mov rcx, rsi
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
mov rcx, rsi
mov rdi, rbx
repne scasw ax, word [rdi]
not rcx
dec rcx
sub r8, rcx
add r8, r8
lea rcx, [rsp + 0x180]
call fcn.14003f7f0
lea rdi, [rsp + 0x450]
xor eax, eax
mov rcx, rsi
repne scasw ax, word [rdi]
mov rax, qword [0x140060ce8]
mov qword [rdi - 2], rax
mov rax, qword [0x140060cf0]
mov qword [rdi + 6], rax
mov eax, dword [0x140060cf8]
mov dword [rdi + 0xe], eax
lea rdi, [rsp + 0x450]
xor eax, eax
mov rcx, rsi
repne scasw ax, word [rdi]
lea r8, [rsp + 0x180]
xor edx, edx
nop dword [rax]
movzx eax, word [r8 + rdx]
mov word [rdi + rdx - 2], ax
add rdx, 2
test ax, ax
jne 0x140007b80
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, [rsp + 0x110]
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x140007bc6
xor eax, eax
jmp 0x140007fc3
mov ebx, r12d
mov r9d, 0x400
lea r8, [rsp + 0x850]
xor edx, edx
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
test eax, eax
jne 0x140007cc3
nop dword [rax]
inc ebx
lea rdx, [rsp + 0x450]
lea rcx, [rsp + 0x850]
call fcn.14003e0b4
test rax, rax
je 0x140007ca0
mov qword [rsp + 0x50], r12
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, [rsp + 0x850]
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140007ca0
movzx eax, r12w
lea rdi, [rsp + 0x250]
mov ecx, pe_nt_image_headers64
rep stosw word [rdi], ax
mov dword [rsp + 0x44], pe_nt_image_headers64
mov dword [rsp + 0x40], r12d
lea rax, [rsp + 0x44]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x250]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x40]
xor r8d, r8d
lea rdx, str.LocationInformation
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x140007cc3
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov r9d, 0x400
lea r8, [rsp + 0x850]
mov edx, ebx
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
test eax, eax
je 0x140007bf0
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea rdx, [rsp + 0x250]
lea rcx, [rsp + 0x30]
call fcn.140009c20
nop
mov edx, 0x3a
mov rcx, qword [rsp + 0x30]
call fcn.14003e11c
test rax, rax
je 0x140007da4
mov rcx, qword [rsp + 0x30]
sub rax, rcx
sar rax, 1
cmp eax, 0xffffffff
je 0x140007da9
mov r8d, eax
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x30]
call fcn.140008780
nop
mov rdx, qword [rax]
lea rcx, [rdx - 0x18]
mov rdi, qword [rsp + 0x30]
add rdi, 0xffffffffffffffe8
cmp rcx, rdi
je 0x140007d7e
cmp dword [rdi + 0x10], 0
jl 0x140007d6f
mov rax, qword [rdi]
cmp qword [rcx], rax
jne 0x140007d6f
call fcn.140009990
mov rbx, rax
mov ecx, esi
lock xadd dword [rdi + 0x10], ecx
dec ecx
test ecx, ecx
jg 0x140007d64
mov rcx, qword [rdi]
mov rax, qword [rcx]
mov rdx, rdi
call qword [rax + 8]
lea rax, [rbx + 0x18]
mov qword [rsp + 0x30], rax
jmp 0x140007d7e
mov r8d, dword [rdx - 0x10]
lea rcx, [rsp + 0x30]
call fcn.140009b30
nop
mov rdx, qword [rsp + 0x60]
add rdx, 0xffffffffffffffe8
mov eax, esi
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140007da4
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
mov rcx, qword [rsp + 0x30]
jmp 0x140007da9
mov rcx, qword [rsp + 0x30]
cmp dword [rcx - 0x10], 0
jl 0x140007e80
lea rdx, [0x140060808]
call fcn.14003e0b4
test rax, rax
je 0x140007e7b
mov rcx, qword [rsp + 0x30]
sub rax, rcx
sar rax, 1
cmp eax, 0xffffffff
je 0x140007e80
mov r8d, dword [rcx - 0x10]
sub r8d, eax
sub r8d, 2
lea rdx, [rsp + 0x58]
lea rcx, [rsp + 0x30]
call fcn.1400086e0
nop
mov rdx, qword [rax]
lea rcx, [rdx - 0x18]
mov rdi, qword [rsp + 0x30]
add rdi, 0xffffffffffffffe8
cmp rcx, rdi
je 0x140007e55
cmp dword [rdi + 0x10], 0
jl 0x140007e46
mov rax, qword [rdi]
cmp qword [rcx], rax
jne 0x140007e46
call fcn.140009990
mov rbx, rax
mov ecx, esi
lock xadd dword [rdi + 0x10], ecx
dec ecx
test ecx, ecx
jg 0x140007e3b
mov rcx, qword [rdi]
mov rax, qword [rcx]
mov rdx, rdi
call qword [rax + 8]
lea rax, [rbx + 0x18]
mov qword [rsp + 0x30], rax
jmp 0x140007e55
mov r8d, dword [rdx - 0x10]
lea rcx, [rsp + 0x30]
call fcn.140009b30
nop
mov rdx, qword [rsp + 0x58]
add rdx, 0xffffffffffffffe8
mov eax, esi
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140007e7b
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
mov rcx, qword [rsp + 0x30]
jmp 0x140007e80
mov rcx, qword [rsp + 0x30]
cmp dword [rcx - 0x10], 0
jle 0x140007fa2
cmp dword [rcx - 8], 1
jle 0x140007ea2
mov edx, dword [rcx - 0x10]
lea rcx, [rsp + 0x30]
call fcn.140003860
mov rcx, qword [rsp + 0x30]
call fcn.140008150
test eax, eax
je 0x140007edf
mov rdx, qword [rsp + 0x30]
movsxd rdi, dword [rdx - 0x10]
cmp dword [rdx - 8], 1
jle 0x140007ecc
mov edx, dword [rdx - 0x10]
lea rcx, [rsp + 0x30]
call fcn.140003860
mov rdx, qword [rsp + 0x30]
mov r8, rdi
add r8, r8
mov rcx, rbp
call fcn.14003f7f0
jmp 0x140007f8e
mov rcx, qword [rsp + 0x30]
cmp dword [rcx - 8], 1
jle 0x140007efc
mov edx, dword [rcx - 0x10]
lea rcx, [rsp + 0x30]
call fcn.140003860
mov rcx, qword [rsp + 0x30]
call fcn.140008090
mov byte [rsp + 0x70], 0
xor ecx, ecx
mov qword [rsp + 0x71], rcx
mov qword [rsp + 0x79], rcx
mov qword [rsp + 0x81], rcx
mov qword [rsp + 0x89], rcx
mov qword [rsp + 0x91], rcx
mov qword [rsp + 0x99], rcx
mov qword [rsp + 0xa1], rcx
mov dword [rsp + 0xa9], ecx
mov word [rsp + 0xad], cx
mov byte [rsp + 0xaf], cl
test rax, rax
je 0x140007f8e
lea rdx, [rsp + 0x70]
mov rcx, rax
call fcn.140008240
test eax, eax
je 0x140007f8e
lea rcx, [rsp + 0x70]
call fcn.140007ff0
mov rdx, rax
xor eax, eax
mov rcx, rsi
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx + rcx - 2]
mov rcx, rbp
call fcn.14003f7f0
mov rdx, rbp
lea rcx, str.GetWSDUrlAddressC_IP___s
call fcn.140005be0
mov rcx, qword [rsp + 0x30]
lea rdx, [rcx - 0x18]
lock xadd dword [rdx + 0x10], esi
dec esi
test esi, esi
jg 0x140007fba
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
mov eax, 1
jmp 0x140007fc3
xor eax, eax
mov rcx, qword [rsp + 0x1050]
xor rcx, rsp
call fcn.14003d6d0
lea r11, [rsp + 0x1060]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r12
pop rdi
pop rsi
ret