Function at 0x18000ad10
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x400]
sub rsp, 0x500
mov rax, qword [0x1800240b0]
xor rax, rsp
mov qword [rbp + 0x3f0], rax
mov rax, qword [rbp + 0x468]
mov qword [rbp - 0x70], r9
mov r15d, r8d
mov qword [rbp - 0x78], rax
mov rax, qword [rbp + 0x470]
mov r13, rdx
mov qword [rsp + 0x78], rax
xor eax, eax
mov qword [rbp - 0x80], rdx
mov qword [rbp - 0x68], rcx
lea r9d, [rax + 4]
xor r8d, r8d
xor edx, edx
xor ecx, ecx
mov ebx, eax
mov r14d, eax
mov dword [rsp + 0x54], eax
mov edi, eax
mov dword [rsp + 0x50], eax
mov r12d, eax
mov dword [rsp + 0x58], eax
call qword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsW]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x18000ada8
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
jmp 0x18000aff2
xor eax, eax
xor edx, edx
test r15b, 2
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x70], rax
mov qword [rsp + 0x60], rax
lea eax, [rdx + 0x40]
mov qword [rsp + 0x6c], rdx
mov qword [rsp + 0x60], r13
cmovne r14d, eax
mov dword [rsp + 0x74], edx
mov dword [rsp + 0x68], edx
test r15b, 0x10
je 0x18000ade2
or r14d, 4
mov r8d, 1
and r15d, 4
je 0x18000ae02
mov rcx, r13
call fcn.18001ef40
xor edx, edx
lea r8d, [rdx + 1]
test eax, eax
cmove edi, r8d
mov rcx, qword [rbp + 0x460]
test rcx, rcx
je 0x18000ae2c
mov rax, qword [rcx]
sub rax, qword [0x180020b48]
jne 0x18000ae25
mov rax, qword [rcx + 8]
sub rax, qword [0x180020b50]
test rax, rax
cmove r12d, r8d
mov rax, qword [rbp - 0x78]
lea r8, [rbp - 0x50]
mov rcx, rsi
mov dword [rax], edx
mov rax, qword [rsp + 0x78]
mov dword [rbp - 0x50], 0x20
mov dword [rax], edx
xor edx, edx
call qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
je 0x18000afe4
movsxd r13, edi
inc dword [rsp + 0x50]
test r15d, r15d
je 0x18000af08
mov rcx, qword [rbp - 0x80]
mov dword [rsp + 0x5c], 0x104
call fcn.18001a410
lea rcx, [rsp + 0x5c]
lea r9, [rbp + 0x1e0]
mov qword [rsp + 0x20], rcx
lea rdx, [rbp - 0x50]
mov rcx, rsi
mov r8, rax
call fcn.18000b270
mov edi, eax
test eax, eax
je 0x18000afcb
mov rax, qword [rbp - 0x80]
mov qword [rsp + 0x60], rax
xor eax, eax
cmp word [rbp + 0x1e0], ax
je 0x18000af1d
lea rcx, [rbp - 0x30]
mov edx, 0x104
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
je 0x18000af1d
lea rdx, [0x180020c10]
lea rcx, [rbp - 0x30]
mov r8d, 0x104
call fcn.18001a2a4
test eax, eax
je 0x18000af1d
lea rdx, [rbp + 0x1e0]
lea rcx, [rbp - 0x30]
mov r8d, 0x104
call fcn.18001a2a4
test eax, eax
je 0x18000af1d
lea rax, [rbp - 0x30]
mov qword [rsp + 0x60], rax
jmp 0x18000af1d
mov r9, qword [rbp - 0x70]
lea rdx, [rbp - 0x50]
mov r8d, r12d
mov rcx, rsi
call fcn.18000b034
mov edi, eax
test edi, edi
je 0x18000afcb
xor edi, edi
lea rdx, [rbp - 0x50]
mov rcx, rsi
test r13, r13
je 0x18000af77
lea r9d, [rdi + 0x10]
lea r8, [rbp - 0x60]
mov dword [rbp - 0x60], 8
mov dword [rbp - 0x5c], 5
mov qword [rbp - 0x58], 1
call qword [sym.imp.SETUPAPI.dll_SetupDiSetClassInstallParamsW]
test eax, eax
je 0x18000af6f
lea r8, [rbp - 0x50]
lea ecx, [rdi + 5]
mov rdx, rsi
call qword [sym.imp.SETUPAPI.dll_SetupDiCallClassInstaller]
test eax, eax
jne 0x18000afb5
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x18000af9c
mov r8, qword [rbp - 0x68]
lea rax, [rsp + 0x60]
mov dword [rsp + 0x30], 3
lea r9, [rsp + 0x58]
mov dword [rsp + 0x28], r14d
mov qword [rsp + 0x20], rax
call fcn.180005590
test eax, eax
je 0x18000afb5
cmp eax, 0x103
jne 0x18000afb1
mov dword [rsp + 0x54], 1
jmp 0x18000afcb
mov ebx, eax
jmp 0x18000afcb
cmp dword [rsp + 0x58], edi
mov rcx, qword [rbp - 0x78]
mov eax, edi
setne al
add dword [rcx], eax
mov rax, qword [rsp + 0x78]
inc dword [rax]
mov edx, dword [rsp + 0x50]
lea r8, [rbp - 0x50]
mov rcx, rsi
call qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
jne 0x18000ae5a
mov rcx, rsi
call qword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
mov r14d, dword [rsp + 0x54]
test ebx, ebx
jne 0x18000b001
test r14d, r14d
mov eax, 0x103
cmovne ebx, eax
mov eax, ebx
mov rcx, qword [rbp + 0x3f0]
xor rcx, rsp
call fcn.180001ac0
mov rbx, qword [rsp + 0x550]
add rsp, 0x500
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret