Function at 0x140020ed0
Capabilities:
Query or enumerate registry value

Disassembly:
mov rax, rsp
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5d8]
sub rsp, 0x6b0
mov qword [rbp - 0x78], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov rax, qword [0x1402698e0]
xor rax, rsp
mov qword [rbp + 0x5a0], rax
mov edi, 4
xor r13d, r13d
mov qword [rsp + 0x20], r13
lea r9, str.Getting_service_parameters_from_Windows_Registry
mov r8d, 0x400003e8
movzx edx, di
lea rcx, [0x140270f20]
call fcn.1400221a0
mov qword [rsp + 0x58], r13
mov dword [rsp + 0x60], r13d
mov qword [rsp + 0x68], r13
mov r9d, 0x20019
lea r8, str.SystemCurrentControlSetServices
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x58]
call fcn.1400225a0
mov ebx, eax
mov qword [rsp + 0x20], r13
mov r8d, 0x400003e8
lea rcx, [0x140270f20]
test eax, eax
je 0x140020f9d
mov r14d, 1
lea r9, str.Unable_to_open_registry_key_services:_SystemCurrentControlSetServices
movzx edx, r14w
call fcn.1400221a0
mov r12, qword [rsp + 0x58]
jmp 0x140021a04
lea r9, str.Opened_registry_key_services:_SystemCurrentControlSetServices
movzx edx, di
call fcn.1400221a0
mov qword [rsp + 0x70], r13
mov dword [rsp + 0x78], r13d
mov qword [rbp - 0x80], r13
mov r9d, 0x20019
lea r8, [0x1402719e0]
mov r12, qword [rsp + 0x58]
mov rdx, r12
lea rcx, [rsp + 0x70]
call fcn.1400225a0
mov ebx, eax
lea r8, [0x1402719e0]
test eax, eax
je 0x14002102b
lea rdx, str.Unable_to_open_registry_key_service_name:__s
lea rcx, [rbp + 0x3a0]
call fcn.140025a90
mov r14d, 1
mov qword [rsp + 0x20], r13
lea r9, [rbp + 0x3a0]
mov r8d, 0x400003e8
movzx edx, r14w
lea rcx, [0x140270f20]
call fcn.1400221a0
mov r15, qword [rsp + 0x70]
jmp 0x1400219f5
lea rdx, str.Opened_registry_key_service_name_:__s
lea rcx, [rbp + 0x1a0]
call fcn.140025a90
mov qword [rsp + 0x20], r13
lea r9, [rbp + 0x1a0]
mov r8d, 0x400003e8
movzx edx, di
lea rcx, [0x140270f20]
call fcn.1400221a0
mov qword [rsp + 0x40], r13
mov dword [rsp + 0x48], r13d
mov qword [rsp + 0x50], r13
mov r9d, 0x20019
lea r8, str.Parameters
mov r15, qword [rsp + 0x70]
mov rdx, r15
lea rcx, [rsp + 0x40]
call fcn.1400225a0
mov ebx, eax
test eax, eax
je 0x1400210c5
mov r14d, 1
mov qword [rsp + 0x20], r13
lea r9, str.Unable_to_open_registry_key_parameters:_Parameters
mov r8d, 0x400003e8
movzx edx, r14w
lea rcx, [0x140270f20]
call fcn.1400221a0
mov rsi, qword [rsp + 0x40]
jmp 0x1400219e6
mov dword [rsp + 0x34], 0x208
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.DisplayName
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
or rdi, 0xffffffffffffffff
test eax, eax
jne 0x1400211a0
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x140021167
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x14002114a
cmp ecx, 2
jbe 0x140021151
cmp ecx, 7
jne 0x14002114a
test al, 1
jne 0x14002114a
mov ecx, eax
shr ecx, 1
cmp ecx, 1
jb 0x14002114a
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x14002114a
cmp ecx, 1
jbe 0x14002116c
cmp word [rbp + rdx*2 - 0x74], 0
je 0x14002116c
mov word [rbp - 0x70], r13w
jmp 0x1400211a0
test al, 1
jne 0x14002114a
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
je 0x14002116c
mov word [rbp - 0x70], r13w
jmp 0x1400211a0
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
inc rax
cmp word [rcx + rax*2], 0
jne 0x140021173
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x1402719d8]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271778]
call fcn.140002df0
mov qword [rsp + 0x20], r13
lea r9, str.Getting_configuration_file_from_Windows_Registry
mov ebx, 4
mov r8d, 0x400003e8
movzx edx, bx
lea rcx, [0x140270f20]
call fcn.1400221a0
mov dword [rsp + 0x34], 0x208
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.ConfigurationFile
mov rsi, qword [rsp + 0x40]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea r14d, [rbx - 3]
test eax, eax
jne 0x1400212b5
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x140021269
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x1400212b0
cmp ecx, 2
jbe 0x140021259
cmp ecx, 7
jne 0x1400212b0
test r14b, al
jne 0x1400212b0
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x1400212b0
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x1400212b0
cmp ecx, r14d
jbe 0x14002126e
cmp word [rbp + rdx*2 - 0x74], 0
jmp 0x1400212ae
test r14b, al
jne 0x1400212b0
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
jmp 0x1400212ae
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
inc rax
cmp word [rcx + rax*2], 0
jne 0x140021275
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x140271988]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271178]
call fcn.140002df0
mov r9, qword [0x140271988]
movzx edx, bx
jmp 0x1400212c0
je 0x14002126e
mov word [rbp - 0x70], r13w
lea r9, str.No_ConfigurationFile_entry
movzx edx, r14w
mov qword [rsp + 0x20], r13
mov r8d, 0x400003e8
lea rcx, [0x140270f20]
call fcn.1400221a0
mov dword [rsp + 0x34], 0x208
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.TraceFile
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x1400213b0
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x140021377
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x140021359
cmp ecx, 2
jbe 0x140021360
cmp ecx, 7
jne 0x140021359
test r14b, al
jne 0x140021359
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x140021359
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x140021359
cmp ecx, r14d
jbe 0x14002137c
cmp word [rbp + rdx*2 - 0x74], 0
je 0x14002137c
mov word [rbp - 0x70], r13w
jmp 0x1400213b0
test r14b, al
jne 0x140021359
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
je 0x14002137c
mov word [rbp - 0x70], r13w
jmp 0x1400213b0
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
inc rax
cmp word [rcx + rax*2], 0
jne 0x140021383
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x1402719d0]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271678]
call fcn.140002df0
mov dword [rsp + 0x34], 0x208
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.DirectorHost
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x14002148d
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x140021450
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x140021432
cmp ecx, 2
jbe 0x140021439
cmp ecx, 7
jne 0x140021432
test r14b, al
jne 0x140021432
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x140021432
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x140021432
cmp ecx, r14d
jbe 0x140021455
cmp word [rbp + rdx*2 - 0x74], 0
je 0x140021455
mov word [rbp - 0x70], r13w
jmp 0x14002148d
test r14b, al
jne 0x140021432
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
je 0x140021455
mov word [rbp - 0x70], r13w
jmp 0x14002148d
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
nop dword [rax]
inc rax
cmp word [rcx + rax*2], 0
jne 0x140021460
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x140271990]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271278]
call fcn.140002df0
mov r8, qword [0x140271990]
lea rdx, str.DirectorHost___s
lea rcx, [rbp + 0x1a0]
call fcn.140025a90
mov qword [rsp + 0x20], r13
lea r9, [rbp + 0x1a0]
mov r8d, 0x400003e8
movzx edx, bx
lea rcx, [0x140270f20]
call fcn.1400221a0
mov dword [rsp + 0x30], r13d
mov dword [rsp + 0x38], ebx
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rax, [0x1402719a8]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.DirectorPort
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x140021512
cmp dword [rsp + 0x30], ebx
jne 0x140021512
mov r8d, dword [0x1402719a8]
jmp 0x14002151f
mov r8d, 0x115c
mov dword [0x1402719a8], r8d
lea rdx, [0x1401cb720]
lea rcx, [0x1402719a0]
call fcn.140020d60
mov dword [rsp + 0x34], 0x208
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.MatcherHost
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x14002160d
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x1400215d2
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x1400215b4
cmp ecx, 2
jbe 0x1400215bb
cmp ecx, 7
jne 0x1400215b4
test r14b, al
jne 0x1400215b4
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x1400215b4
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x1400215b4
cmp ecx, r14d
jbe 0x1400215d7
cmp word [rbp + rdx*2 - 0x74], 0
je 0x1400215d7
mov word [rbp - 0x70], r13w
jmp 0x14002160d
test r14b, al
jne 0x1400215b4
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
je 0x1400215d7
mov word [rbp - 0x70], r13w
jmp 0x14002160d
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
nop
inc rax
cmp word [rcx + rax*2], 0
jne 0x1400215e0
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x140271998]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271378]
call fcn.140002df0
mov dword [rsp + 0x30], r13d
mov dword [rsp + 0x38], ebx
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rax, [0x140271c20]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.ListenPort
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x140021657
cmp dword [rsp + 0x30], ebx
jne 0x140021657
mov r8d, dword [0x140271c20]
jmp 0x140021661
mov r8d, r13d
mov dword [0x140271c20], r13d
lea rdx, [0x1401cb720]
lea rcx, [0x140271c18]
call fcn.140020d60
mov dword [rsp + 0x34], reloc.WS2_32.dll_select
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.ServerId
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x14002174d
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x140021714
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x1400216f6
cmp ecx, 2
jbe 0x1400216fd
cmp ecx, 7
jne 0x1400216f6
test r14b, al
jne 0x1400216f6
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x1400216f6
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x1400216f6
cmp ecx, r14d
jbe 0x140021719
cmp word [rbp + rdx*2 - 0x74], 0
je 0x140021719
mov word [rbp - 0x70], r13w
jmp 0x14002174d
test r14b, al
jne 0x1400216f6
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
je 0x140021719
mov word [rbp - 0x70], r13w
jmp 0x14002174d
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
inc rax
cmp word [rcx + rax*2], 0
jne 0x140021720
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x1402719b0]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271478]
call fcn.140002df0
mov dword [rsp + 0x34], ebx
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.SystemId
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x140021826
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x1400217df
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x140021821
cmp ecx, 2
jbe 0x1400217cf
cmp ecx, 7
jne 0x140021821
test r14b, al
jne 0x140021821
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x140021821
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], 0
jne 0x140021821
cmp ecx, r14d
jbe 0x1400217e4
cmp word [rbp + rdx*2 - 0x74], 0
jmp 0x14002181f
test r14b, al
jne 0x140021821
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
jmp 0x14002181f
mov word [rbp - 0x70], r13w
lea rcx, [rbp - 0x70]
mov rax, rdi
nop dword [rax + rax]
inc rax
cmp word [rcx + rax*2], 0
jne 0x1400217f0
mov r8d, eax
lea rdx, [rbp - 0x70]
lea rcx, [0x1402719b8]
call fcn.140024d20
lea rdx, [rbp - 0x70]
lea rcx, [0x140271578]
call fcn.140002df0
jmp 0x140021848
je 0x1400217e4
mov word [rbp - 0x70], r13w
mov qword [rsp + 0x20], r13
lea r9, str.No_SystemId_entry
mov r8d, 0x400003e8
movzx edx, r14w
lea rcx, [0x140270f20]
call fcn.1400221a0
mov dword [rsp + 0x30], r13d
mov dword [rsp + 0x38], ebx
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rax, [0x1402719c8]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.MaximumThreads
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x140021892
cmp dword [rsp + 0x30], ebx
jne 0x140021892
mov r8d, dword [0x1402719c8]
jmp 0x14002189f
mov r8d, 8
mov dword [0x1402719c8], r8d
lea rdx, [0x1401cb720]
lea rcx, [0x1402719c0]
call fcn.140020d60
mov dword [rsp + 0x30], r13d
lea rax, [rsp + 0x34]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
xor r8d, r8d
lea rdx, str.ProcessLevel
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ebx, eax
test eax, eax
jne 0x140021949
mov eax, dword [rsp + 0x34]
test eax, eax
je 0x140021944
mov ecx, dword [rsp + 0x30]
test ecx, ecx
je 0x140021928
cmp ecx, 2
jbe 0x140021934
cmp ecx, 7
jne 0x140021928
test r14b, al
jne 0x140021928
mov ecx, eax
shr ecx, 1
cmp ecx, r14d
jb 0x140021928
mov edx, eax
shr rdx, 1
cmp word [rbp + rdx*2 - 0x72], bx
jne 0x140021928
cmp ecx, r14d
jbe 0x140021949
cmp word [rbp + rdx*2 - 0x74], bx
je 0x140021949
mov word [rbp - 0x70], r13w
mov ebx, reloc.WS2_32.dll_listen
jmp 0x14002196e
test r14b, al
jne 0x140021928
shr rax, 1
cmp word [rbp + rax*2 - 0x72], 0
jmp 0x140021926
mov word [rbp - 0x70], r13w
test ebx, ebx
jne 0x14002196e
lea rax, [rbp - 0x70]
inc rdi
cmp word [rax + rdi*2], 0
jne 0x140021951
mov r8d, edi
lea rdx, [rbp - 0x70]
lea rcx, [0x140271c28]
call fcn.140024d20
test rsi, rsi
je 0x140021984
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rsi, r13
mov qword [rsp + 0x40], r13
mov dword [rsp + 0x48], r13d
test r15, r15
je 0x14002199f
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov r15, r13
mov qword [rsp + 0x70], r13
mov dword [rsp + 0x78], r13d
test r12, r12
je 0x1400219ba
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov r12, r13
mov qword [rsp + 0x58], r13
mov dword [rsp + 0x60], r13d
mov qword [rsp + 0x20], r13
lea r9, str.Finished_getting_service_parameters_from_Windows_Registry
mov edi, 4
mov r8d, 0x400003e8
movzx edx, di
lea rcx, [0x140270f20]
call fcn.1400221a0
nop
test rsi, rsi
je 0x1400219f5
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
test r15, r15
je 0x140021a04
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
test r12, r12
je 0x140021a12
mov rcx, r12
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
mov rcx, qword [rbp + 0x5a0]
xor rcx, rsp
call fcn.14019aa20
lea r11, [rsp + 0x6b0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret