Function at 0x14003218c
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0xc8]
sub rsp, 0x1a0
mov rax, qword [0x1400d9180]
xor rax, rsp
mov qword [rbp + 0x90], rax
xor ebx, ebx
lea rcx, [rsp + 0x5c]
xor edx, edx
lea r8d, [rbx + 0x1c]
mov r15d, ebx
mov dword [rsp + 0x58], 0x20
call fcn.14005bab0
cmp qword [0x1400dbf70], rbx
mov word [rsp + 0x40], 1
jne 0x140032201
lea rcx, str._DisableOnSoftRemove:_no_bt_device_n
call fcn.1400300fc
jmp 0x140032525
lea rcx, [0x14009e5a0]
mov r9d, 2
xor r8d, r8d
xor edx, edx
call qword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsW]
mov r13, rax
mov qword [rsp + 0x50], rax
test rax, rax
jne 0x14003223f
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str._DisableOnSoftRemove:_SetupDiGetClassDevs_failed._err_d_n
mov edx, eax
call fcn.1400300fc
jmp 0x140032525
mov r12d, ebx
lea r8, [rsp + 0x58]
mov edx, r12d
mov rcx, r13
call qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
je 0x1400324fb
xor r9d, r9d
lea rax, [rbp - 0x80]
mov qword [rsp + 0x30], rbx
lea rdx, [rsp + 0x58]
lea r8d, [r9 + 1]
mov rcx, r13
mov dword [rsp + 0x28], 0x104
mov qword [rsp + 0x20], rax
call qword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceRegistryPropertyA]
test eax, eax
jne 0x1400322a3
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str._DisableOnSoftRemove:_SetupDiGetDeviceRegistryProperty_failed._err_d_n
mov edx, eax
call fcn.1400300fc
jmp 0x1400324e9
lea rcx, [rbp - 0x80]
mov edx, 0x104
movzx edi, bx
movzx esi, bx
movzx r14d, bx
call fcn.14005d740
cmp byte [rbp - 0x80], 0
lea rbx, [rbp - 0x80]
je 0x1400324d7
xor r13d, r13d
lea rdx, str.VID_
mov rcx, rbx
call fcn.14005c79c
test rax, rax
je 0x14003234c
xor edx, edx
lea rcx, [rax + 4]
lea r8d, [rdx + 0x10]
call fcn.140061530
lea rdx, str.PID_
mov rcx, rbx
mov r14d, eax
call fcn.14005c79c
test rax, rax
je 0x14003234c
xor edx, edx
lea rcx, [rax + 4]
lea r8d, [rdx + 0x10]
call fcn.140061530
lea rdx, str.REV_
mov rcx, rbx
mov esi, eax
call fcn.14005c79c
test rax, rax
je 0x14003234c
xor edx, edx
lea rcx, [rax + 4]
lea r8d, [rdx + 0x10]
call fcn.140061530
mov edi, eax
test r14w, r14w
je 0x14003234c
test si, si
je 0x14003234c
test ax, ax
jne 0x140032362
mov rcx, rbx
call fcn.14005bc90
lea rbx, [rbx + rax + 1]
cmp byte [rbx], r13b
jne 0x1400322cc
mov r13, qword [rsp + 0x50]
xor ebx, ebx
test r14w, r14w
je 0x1400324d9
test si, si
je 0x1400324d9
test di, di
je 0x1400324d9
movzx ebx, di
movzx edi, si
movzx esi, r14w
lea rcx, str.DisableOnSoftRemove:_found_VID:_04x_PID:_04x_REV:_04x_n
mov edx, esi
mov r9d, ebx
mov r8d, edi
call fcn.1400300fc
lea r8, str.SYSTEMCurrentControlSetControlusbflags_04x_04x_04x
lea rcx, [rbp - 0x80]
mov r9d, esi
mov edx, 0x104
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], edi
call fcn.14005d88c
lea r11, [rsp + 0x48]
lea rdx, [rbp - 0x80]
mov r9d, 0x2001f
xor r8d, r8d
mov rcx, 0xffffffff80000002
mov qword [rsp + 0x20], r11
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
xor ebx, ebx
test eax, eax
je 0x1400323f9
lea rcx, str._DisableOnSoftRemove:_RegOpenKeyEx_failed._err_d_n
jmp 0x140032297
mov rcx, qword [rsp + 0x48]
lea rax, [rsp + 0x44]
lea rdx, str.DisableOnSoftRemove
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x44], 2
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x140032487
lea rcx, str.DisableOnSoftRemove:_no_value._RegQueryValueEx_returned__d_n
mov edx, eax
call fcn.1400300fc
mov rcx, qword [rsp + 0x48]
lea rax, [rsp + 0x40]
lea rdx, str.DisableOnSoftRemove
mov r9d, 3
xor r8d, r8d
mov dword [rsp + 0x28], 2
mov qword [rsp + 0x20], rax
mov word [rsp + 0x40], 1
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x1400324c4
lea rcx, str._DisableOnSoftRemove:_RegSetValueEx_failed._err_d_n
mov edx, eax
call fcn.1400300fc
jmp 0x1400324ca
mov edx, dword [rsp + 0x44]
cmp edx, 2
je 0x1400324a5
lea rcx, str.DisableOnSoftRemove:_wrong_value_length__d_n
call fcn.1400300fc
mov r11b, bl
mov byte [rsp + 0x40], bl
jmp 0x1400324aa
mov r11b, byte [rsp + 0x40]
cmp r11b, 1
jne 0x14003243f
cmp byte [rsp + 0x41], bl
jne 0x14003243f
lea rcx, str.DisableOnSoftRemove:_value_exists_already_n
call fcn.1400300fc
jmp 0x1400324ca
mov r15d, 1
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x1400324e9
xor ebx, ebx
lea rdx, [rbp - 0x80]
lea rcx, str.DisableOnSoftRemove:_ignore_dev_with_HARDWAREID__hs_n
call fcn.1400300fc
inc r12d
cmp r12d, 0x3e8
jb 0x140032242
jmp 0x14003251c
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x103
je 0x14003251c
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str._DisableOnSoftRemove:_SetupDiEnumDeviceInfo_failed._err_d_n
mov edx, eax
call fcn.1400300fc
mov rcx, r13
call qword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
mov eax, r15d
mov rcx, qword [rbp + 0x90]
xor rcx, rsp
call fcn.14005ba20
lea r11, [rsp + 0x1a0]
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