Function at 0x140001280
Capabilities:
Connect to wmi namespace via wbemlocator
Query or enumerate registry value
Terminate process

Disassembly:
push rbp
push rbx
push r14
lea rbp, [rsp - 0x310]
sub rsp, 0x410
mov rax, qword [section..data]
xor rax, rsp
mov qword [rbp + 0x300], rax
mov r8d, 0x103
lea rdx, [rbp + 0xf0]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea rax, [0x140003488]
mov qword [rbp - 0x80], rax
lea rcx, str.ROOTCimV2
lea rax, [0x1400034a8]
mov qword [rbp - 0x78], rax
lea rax, [0x1400034c8]
mov qword [rbp - 0x70], rax
lea rax, [0x1400034e8]
mov qword [rbp - 0x68], rax
lea rax, [0x140003508]
mov qword [rbp - 0x60], rax
lea rax, [0x140003528]
mov qword [rbp - 0x58], rax
lea rax, str.ACPIQCOM05970
mov qword [rsp + 0x50], rax
lea rax, str.ACPIQCOM03040
mov qword [rsp + 0x58], rax
lea rax, str.ACPIQCOM1A8B0
mov qword [rsp + 0x60], rax
lea rax, str.ACPIQCOM04970
mov qword [rsp + 0x68], rax
lea rax, str.ACPIQCOM08970
mov qword [rsp + 0x70], rax
lea rax, str.ACPIINT33A00
mov qword [rsp + 0x78], rax
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
xor edx, edx
xor ecx, ecx
mov rbx, rax
call qword [sym.imp.ole32.dll_CoInitializeEx]
xor r14d, r14d
xor r9d, r9d
xor r8d, r8d
mov dword [0x140005668], eax
mov qword [rsp + 0x40], r14
xor ecx, ecx
mov dword [rsp + 0x38], r14d
mov qword [rsp + 0x30], r14
lea edx, [r14 - 1]
mov dword [rsp + 0x28], 3
mov dword [rsp + 0x20], r14d
call qword [sym.imp.ole32.dll_CoInitializeSecurity]
mov dword [0x140005668], eax
lea r9, [0x1400032c0]
lea rax, [0x140005660]
xor edx, edx
lea r8d, [r14 + 1]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400032d0]
call qword [sym.imp.ole32.dll_CoCreateInstance]
mov dword [0x140005668], eax
test eax, eax
jns 0x1400013dc
call qword [sym.imp.ole32.dll_CoUninitialize]
lea ecx, [r14 + 1]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
mov rcx, qword [0x140005660]
lea rdx, [0x140005670]
mov qword [rsp + 0x40], rdx
xor r9d, r9d
mov qword [rsp + 0x38], r14
xor r8d, r8d
mov qword [rsp + 0x430], rsi
mov rdx, rbx
mov rax, qword [rcx]
mov qword [rsp + 0x30], r14
mov qword [rsp + 0x438], rdi
mov dword [rsp + 0x28], r14d
mov qword [rsp + 0x440], r15
mov qword [rsp + 0x20], r14
call qword [rax + 0x18]
mov rcx, rbx
mov dword [0x140005668], eax
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
xorps xmm0, xmm0
mov dword [rbp - 0x38], r14d
xor eax, eax
mov word [rbp + 0x60], r14w
movups xmmword [rbp + 0x62], xmm0
mov dword [rbp + 0xe2], eax
mov edi, r14d
movups xmmword [rbp + 0x72], xmm0
lea rsi, [rsp + 0x50]
movups xmmword [rbp + 0x82], xmm0
lea r15, [0x140003634]
movups xmmword [rbp + 0x92], xmm0
movups xmmword [rbp + 0xa2], xmm0
movups xmmword [rbp + 0xb2], xmm0
movups xmmword [rbp + 0xc2], xmm0
movups xmmword [rbp + 0xd2], xmm0
nop
mov rax, qword [rsi]
lea r9, str.Select__from_Win32_PnPEntity_Where_DeviceID__
mov qword [rsp + 0x28], r15
lea r8, str._ls_ls_ls
mov edx, 0x43
mov qword [rsp + 0x20], rax
lea rcx, [rbp + 0x60]
call fcn.140001010
lea rcx, [rbp + 0x60]
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
lea rcx, [0x140003318]
mov qword [rbp - 0x48], r14
mov rbx, rax
mov qword [rbp - 0x40], r14
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov rcx, qword [0x140005670]
lea rdx, [rbp - 0x48]
mov qword [rsp + 0x28], rdx
mov r9d, 0x20
mov r8, rbx
mov qword [rsp + 0x20], r14
mov rdx, rax
mov r10, qword [rcx]
call qword [r10 + 0xa0]
mov rcx, qword [rbp - 0x48]
lea rdx, [rbp - 0x38]
mov qword [rsp + 0x20], rdx
lea r9, [rbp - 0x40]
mov edx, 0xffffffff
mov dword [0x140005668], eax
mov rax, qword [rcx]
lea r8d, [rdx + 2]
call qword [rax + 0x20]
mov rcx, qword [rbp - 0x48]
mov dword [0x140005668], eax
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rbp - 0x40]
test rcx, rcx
je 0x14000154b
mov rax, qword [rcx]
call qword [rax + 0x10]
cmp dword [rbp - 0x38], r14d
ja 0x140001586
inc edi
add rsi, 8
cmp edi, 6
jb 0x140001490
mov r9d, 0x10
lea r8, str.USB_Host_Mode_Control_V7.0___Native_
lea rdx, str.Your_device_is_not_supported_
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxW]
mov eax, 1
jmp 0x140001719
mov rcx, qword [0x140005670]
movsxd rax, edi
mov rbx, qword [rbp + rax*8 - 0x80]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [0x140005660]
mov rax, qword [rcx]
call qword [rax + 0x10]
call qword [sym.imp.ole32.dll_CoUninitialize]
xorps xmm0, xmm0
mov word [rbp - 0x20], r14w
xor eax, eax
lea r9, str.SYSTEMCurrentControlSetEnum_
mov qword [rbp + 0x52], rax
lea r8, str._ls_ls_ls
mov dword [rbp + 0x5a], eax
lea rcx, [rbp - 0x20]
lea rax, str.Device_Parameters
mov edx, 0x3f
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rbx
movups xmmword [rbp - 0x1e], xmm0
movups xmmword [rbp - 0xe], xmm0
movups xmmword [rbp + 2], xmm0
movups xmmword [rbp + 0x12], xmm0
movups xmmword [rbp + 0x22], xmm0
movups xmmword [rbp + 0x32], xmm0
movups xmmword [rbp + 0x42], xmm0
call fcn.140001010
mov qword [rsp + 0x40], r14
lea rax, [rbp - 0x50]
mov qword [rsp + 0x38], rax
lea rdx, [rbp - 0x20]
mov qword [rsp + 0x30], r14
xor r9d, r9d
mov dword [rsp + 0x28], 0xf003f
xor r8d, r8d
mov rcx, 0xffffffff80000002
mov dword [rsp + 0x20], r14d
mov qword [rbp - 0x50], r14
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov dword [0x140005690], eax
test eax, eax
je 0x140001673
mov r9d, 0x10
lea r8, str.USB_Host_Mode_Control_V7.0___Native_
lea rdx, str.couldnt_open_the_registry_key
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxW]
mov eax, 1
jmp 0x140001719
mov rcx, qword [rbp - 0x50]
lea rax, [rbp - 0x34]
mov qword [rsp + 0x28], rax
lea rdx, str.RoleSwitchMode
lea rax, [rbp - 0x30]
mov dword [rbp - 0x34], 4
xor r9d, r9d
mov qword [rsp + 0x20], rax
xor r8d, r8d
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov dword [0x140005690], eax
test eax, eax
je 0x1400016c9
mov r9d, 0x10
lea r8, str.USB_Host_Mode_Control_V7.0___Native_
lea rdx, str.couldnt_read_the_registry_key
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxW]
mov eax, dword [rbp - 0x30]
cmp al, 1
jne 0x1400016e3
mov r9b, 3
lea r8, str.disable
lea rdx, str.enabled
jmp 0x1400016ff
lea r8, str.enable
mov r9b, 1
lea rdx, str.disabled
cmp al, 3
je 0x1400016ff
lea rdx, str.in_an_unknown_state
mov rcx, qword [rbp - 0x50]
mov qword [rsp + 0x20], rbx
call fcn.1400010d0
mov rcx, qword [rbp - 0x50]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
mov rdi, qword [rsp + 0x438]
mov rsi, qword [rsp + 0x430]
mov r15, qword [rsp + 0x440]
mov rcx, qword [rbp + 0x300]
xor rcx, rsp
call fcn.140001760
add rsp, 0x410
pop r14
pop rbx
pop rbp
ret