Function at 0x140011870
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
push r15
push r14
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x50
mov rbx, rcx
mov rax, qword [0x140047010]
xor rax, rsp
mov qword [rsp + 0x48], rax
xor edi, edi
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_GetLongPathNameW]
test eax, eax
je 0x1400119bb
mov ebp, eax
mov esi, eax
add rsi, rsi
mov rcx, rsi
call fcn.140013644
mov r12, rax
xor edi, edi
mov rcx, rax
xor edx, edx
mov r8, rsi
call fcn.140015c00
mov rcx, rbx
mov rdx, r12
mov r8d, ebp
call qword [sym.imp.KERNEL32.dll_GetLongPathNameW]
test eax, eax
je 0x1400119b3
lea r15, [rsp + 0x40]
mov qword [r15], 0
lea rcx, [0x140036028]
xor edx, edx
xor r8d, r8d
mov r9, r15
call sub.SHELL32.dll_SHGetKnownFolderPath
test eax, eax
js 0x1400119b1
mov rbx, qword [rsp + 0x40]
mov rcx, rbx
call fcn.140013730
test rax, rax
je 0x1400119a3
mov rdi, rax
cmp word [rbx + rax*2 - 2], 0x5c
jne 0x1400119d9
mov rcx, r12
mov rdx, rbx
mov r8, rdi
call fcn.14001f870
test eax, eax
je 0x140011a38
mov rcx, rbx
call qword [sym.imp.ole32.dll_CoTaskMemFree]
mov dword [rsp + 0x40], 0
mov qword [rsp + 0x30], r15
xorps xmm0, xmm0
movups xmmword [rsp + 0x20], xmm0
lea rdx, str.SoftwareMicrosoftWindowsCurrentVersion
lea r8, str.ProgramFilesDir
mov rcx, 0xffffffff80000002
mov r9d, 0x10002
call qword [sym.imp.ADVAPI32.dll_RegGetValueW]
mov esi, 1
test eax, eax
jne 0x140011996
mov ebx, dword [rsp + 0x40]
cmp rbx, 4
jae 0x140011a49
xor ebp, ebp
test esi, esi
setne dil
and dil, bpl
jmp 0x1400119b3
test rbx, rbx
je 0x1400119b1
mov rcx, rbx
call qword [sym.imp.ole32.dll_CoTaskMemFree]
xor edi, edi
mov rcx, r12
call fcn.1400138e8
mov rcx, qword [rsp + 0x48]
xor rcx, rsp
call fcn.1400246e0
mov eax, edi
add rsp, 0x50
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r14
pop r15
ret
lea r14, [rdi + 1]
add rdi, 2
mov rax, rdi
add rax, rdi
mov rbp, 0xffffffffffffffff
cmovae rbp, rax
mov rcx, rbp
call fcn.140013644
mov rsi, rax
mov rcx, rax
xor edx, edx
mov r8, rbp
call fcn.140015c00
mov rcx, rsi
mov rdx, rdi
mov r9, rbx
call fcn.140011b60
mov rcx, r12
mov rdx, rsi
mov r8, r14
call fcn.14001f870
mov edi, eax
mov rcx, rsi
call fcn.1400138e8
test edi, edi
jne 0x140011940
mov rcx, rbx
call qword [sym.imp.ole32.dll_CoTaskMemFree]
mov dil, 1
jmp 0x1400119b3
mov esi, ebx
and esi, 0xfffffffe
mov rcx, rsi
call fcn.140013644
mov r14, rax
xor ebp, ebp
mov rcx, rax
xor edx, edx
mov r8, rsi
call fcn.140015c00
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x28], r14
mov qword [rsp + 0x20], 0
lea rdx, str.SoftwareMicrosoftWindowsCurrentVersion
lea r8, str.ProgramFilesDir
mov rcx, 0xffffffff80000002
mov r9d, 0x10002
call qword [sym.imp.ADVAPI32.dll_RegGetValueW]
mov esi, 1
test eax, eax
je 0x140011ab2
mov rcx, r14
call fcn.1400138e8
jmp 0x140011998
shr rbx, 1
mov rcx, r14
mov rdx, rbx
call fcn.14002299c
test rax, rax
je 0x140011ae8
mov rdi, rax
cmp word [r14 + rax*2 - 2], 0x5c
jne 0x140011aec
mov rcx, r12
mov rdx, r14
mov r8, rdi
call fcn.14001f870
test eax, eax
jne 0x140011b47
mov bpl, 1
jmp 0x140011aa5
xor ebp, ebp
jmp 0x140011aa5
lea r15, [rdi + 1]
add rdi, 2
mov rax, rdi
add rax, rdi
mov rbx, 0xffffffffffffffff
cmovae rbx, rax
mov rcx, rbx
call fcn.140013644
mov rbp, rax
mov rcx, rax
xor edx, edx
mov r8, rbx
call fcn.140015c00
mov rcx, rbp
mov rdx, rdi
mov r9, r14
call fcn.140011b60
mov rcx, r12
mov rdx, rbp
mov r8, r15
call fcn.14001f870
mov edi, eax
mov rcx, rbp
call fcn.1400138e8
test edi, edi
je 0x140011ae3
mov bpl, 1
xor esi, esi
jmp 0x140011aa5