Function at 0x140114890
Capabilities:
Check if file exists
Get common file path
Get file attributes
Query environment variable
Query or enumerate registry value

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x2648]
mov eax, 0x2748
call fcn.1401e4640
sub rsp, rax
mov rax, qword [0x1402ea100]
xor rax, rsp
mov qword [rbp + 0x2630], rax
mov qword [rbp - 0x48], r9
mov r15, r8
mov rsi, rdx
mov qword [rbp - 0x78], rcx
mov rax, qword [rbp + 0x26b8]
mov qword [rbp - 0x50], rax
mov r13, qword [rbp + 0x26c0]
mov qword [rbp - 0x38], r13
xor r14d, r14d
xor edx, edx
mov r8d, 0x2000
lea rcx, [rbp + 0x630]
call fcn.14026bb60
lea rcx, [rbp - 0x30]
call fcn.1400dde00
nop
mov rdx, rsi
lea rcx, [rsp + 0x68]
call fcn.1400d3970
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.14010b570
mov rdi, rax
cmp rsi, rax
je 0x140114958
mov rcx, rsi
call fcn.1400d4220
mov rcx, rdi
call fcn.1400d4220
mov rbx, rax
mov rcx, rsi
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
mov rdx, rdi
mov rcx, rsi
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
mov rdx, rsi
lea rcx, [rbp - 8]
call fcn.14010ae00
nop
cmp dword [0x140380abc], 9
ja 0x140114a62
lea rcx, [0x1402acfd0]
call fcn.1400ce070
mov rdi, rax
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r13, rax
cmp rdi, rbx
ja 0x140114a5e
sub rbx, rdi
test rdi, rdi
je 0x140114a18
lea r12, [rbx*2]
mov rbx, rax
nop word [rax + rax]
lea rax, [r13 + 2]
add rax, r12
sub rax, rbx
sar rax, 1
mov rcx, r14
je 0x1401149ee
cmp word [rbx], 0x65
je 0x1401149eb
cmp rax, 1
je 0x1401149ee
dec rax
add rbx, 2
cmp word [rbx], 0x65
jne 0x1401149d8
mov rcx, rbx
mov rbx, rcx
test rcx, rcx
je 0x140114a5e
mov r8, rdi
lea rdx, [0x1402acfd0]
call fcn.1400d4550
test eax, eax
je 0x140114a0f
add rbx, 2
jmp 0x1401149c0
sub rbx, r13
cmp rbx, 2
jae 0x140114a5e
mov qword [rbp + 0x18], 4
mov rax, qword [rbp + 8]
mov qword [rsp + 0x60], rax
lea rdx, [rsp + 0x60]
lea rcx, [rbp + 0x18]
call fcn.1400ae310
mov rbx, qword [rax]
mov rdi, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400da280
sub rdi, rbx
lea r8, [rdi + 1]
lea rdx, [rax + rbx*2]
mov rcx, rax
call fcn.1400ed7e0
mov qword [rbp + 8], rdi
mov r13, qword [rbp - 0x38]
mov rdi, qword [rbp - 0x78]
add rdi, 8
mov rax, qword [rdi]
mov qword [rbp - 0x78], rax
mov rdx, rdi
lea rcx, [rbp - 0x78]
call fcn.140072660
mov rbx, qword [rbp - 0x78]
mov rax, qword [rdi]
mov rcx, qword [rax]
mov qword [rbp + 0x18], rcx
mov rdx, rdi
lea rcx, [rbp + 0x18]
call fcn.140072660
mov rax, qword [rbp + 0x18]
mov qword [rbp - 0x10], rax
xor edx, edx
lea rcx, [rbp - 0x10]
call fcn.140072660
mov qword [rbp - 0x38], rbx
xor edx, edx
lea rcx, [rbp - 0x38]
call fcn.140072660
mov rbx, qword [rbp - 0x10]
cmp rbx, qword [rbp - 0x38]
je 0x140114aef
lea rcx, [rbx + 0x10]
call fcn.1400d3890
mov rdx, rax
lea rcx, [rbp - 8]
call fcn.140116000
mov rbx, qword [rbp - 0x10]
cmp rax, 0xffffffffffffffff
jne 0x140114aef
mov rbx, qword [rbx]
mov qword [rbp - 0x10], rbx
cmp rbx, qword [rbp - 0x38]
jne 0x140114ac3
mov rax, qword [rdi]
mov qword [rsp + 0x60], rax
mov rdx, rdi
lea rcx, [rsp + 0x60]
call fcn.140072660
cmp rbx, qword [rsp + 0x60]
je 0x140114c33
mov rcx, qword [rbx + 0x30]
cmp rcx, qword [rbx + 0x38]
je 0x140114b33
mov rdx, r15
call fcn.1400d4b70
test al, al
jne 0x140114b2b
mov r15, qword [rbx + 0x30]
jmp 0x140114b33
mov r15, qword [rbx + 0x38]
sub r15, 0x20
mov rcx, rsi
mov rdx, r15
call fcn.1400ecd70
mov r9, r13
mov r8, qword [rbp - 0x50]
mov rdx, rsi
call fcn.1401154c0
mov edx, 0x80000000
lea ecx, [rax + rdx]
test edx, ecx
jne 0x140115450
cmp eax, 0xc015001d
je 0x140115450
test byte [rbp + 0x26b0], 2
je 0x140115453
xor edx, edx
mov r8d, 0x1fe
lea rcx, [rbp + 0x30]
call fcn.14026bb60
mov edx, 0xff
lea rcx, [rbp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea rdx, [rbp + 0x30]
lea rcx, [rbp - 0x70]
call fcn.1400d39f0
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
nop
mov rbx, qword [rsi + 0x10]
mov rcx, rsi
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rdx, [rsp + 0x40]
mov rcx, rsi
call fcn.1400ecdd0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
jmp 0x140115453
mov r15d, dword [rbp + 0x26b0]
test r15b, 1
jne 0x140114c73
mov r9, r13
mov r13, qword [rbp - 0x50]
mov r8, r13
mov rdx, rsi
call fcn.1401154c0
mov edx, 0x80000000
lea ecx, [rax + rdx]
test edx, ecx
jne 0x140115450
cmp eax, 0xc015001d
je 0x140115450
test r15b, 4
je 0x140114c7e
mov r14d, 0xc0000225
jmp 0x140115453
mov rcx, rsi
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x140115453
mov qword [rbp + 0x20], r14
lea r8, [rbp + 0x20]
lea rdx, str.SYSTEMCurrentControlSetControlSession_ManagerKnownDLLs
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
movsxd rdi, eax
test eax, eax
jne 0x140114da3
mov ebx, r14d
test rdi, rdi
jne 0x140114da3
xor edx, edx
mov r8d, 0x1fe
lea rcx, [rbp + 0x430]
call fcn.14026bb60
xor edx, edx
mov r8d, 0x1fe
lea rcx, [rbp + 0x230]
call fcn.14026bb60
mov dword [rbp - 0x38], 0xff
mov dword [rbp - 0x10], r14d
lea rax, [rbp - 0x38]
mov qword [rsp + 0x38], rax
lea rax, [rbp + 0x230]
mov qword [rsp + 0x30], rax
lea rax, [rbp - 0x10]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r14
lea r9, [rbp - 0x38]
lea r8, [rbp + 0x430]
mov edx, ebx
mov rcx, qword [rbp + 0x20]
call qword [sym.imp.ADVAPI32.dll_RegEnumValueW]
movsxd rdi, eax
lea rcx, [rbp - 8]
call fcn.1400d3890
mov rdx, rax
lea rcx, [rbp + 0x230]
call fcn.14023c680
test eax, eax
jne 0x140114d95
xor edx, edx
mov r8d, 0x1fe
lea rcx, [rbp + 0x30]
call fcn.14026bb60
mov dword [rbp - 0x38], 0xff
mov edx, 0xff
lea rcx, [rbp + 0x30]
test r15b, 8
je 0x140114d86
call qword [sym.imp.KERNEL32.dll_GetSystemWow64DirectoryW]
jmp 0x140114d8c
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test rdi, rdi
je 0x140114f52
inc ebx
cmp ebx, 0x1000
jl 0x140114cc2
mov rax, qword [rbp - 0x48]
cmp qword [rax + 0x10], 0
je 0x140114e54
lea r8, [0x1402acfcc]
mov rdx, rax
lea rcx, [rbp - 0x70]
call fcn.140117190
mov rdi, rax
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
mov rcx, rdi
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rcx, [rbp - 0x30]
call fcn.1400d4220
lea rcx, [rsp + 0x40]
call fcn.1400d4220
mov rbx, rax
lea rcx, [rbp - 0x30]
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x30]
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
lea rcx, [rbp - 0x30]
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1401152c2
mov r8d, dword [r13 + 8]
lea rdx, [rbp - 0x70]
call fcn.140115a20
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
nop
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rcx, [rbp - 0x30]
call fcn.1400d4220
lea rcx, [rsp + 0x40]
call fcn.1400d4220
mov rbx, rax
lea rcx, [rbp - 0x30]
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x30]
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
lea rcx, [rbp - 0x30]
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1401152c2
mov edx, 0x1000
lea rcx, [rbp + 0x630]
test r15b, 8
je 0x140114ffc
call qword [sym.imp.KERNEL32.dll_GetSystemWow64DirectoryW]
jmp 0x140115002
lea rdx, [rbp + 0x30]
lea rcx, [rbp - 0x70]
call fcn.1400d39f0
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
nop
lea rcx, [rbp + 0x230]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [rbp + 0x230]
lea rcx, [rsp + 0x40]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
lea rdx, [rsp + 0x68]
mov rcx, rsi
call fcn.1400ecdd0
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
jmp 0x14011543f
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea rdx, [rbp + 0x630]
lea rcx, [rbp - 0x70]
call fcn.1400d39f0
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
nop
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rcx, [rbp - 0x30]
call fcn.1400d4220
lea rcx, [rsp + 0x40]
call fcn.1400d4220
mov rbx, rax
lea rcx, [rbp - 0x30]
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x30]
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
lea rcx, [rbp - 0x30]
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1401152c2
mov edx, 0x1000
lea rcx, [rbp + 0x630]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
lea rdx, [rbp + 0x630]
lea rcx, [rbp - 0x70]
call fcn.1400d39f0
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
nop
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rcx, [rbp - 0x30]
call fcn.1400d4220
lea rcx, [rsp + 0x40]
call fcn.1400d4220
mov rbx, rax
lea rcx, [rbp - 0x30]
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x30]
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
lea rcx, [rbp - 0x30]
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1401152c2
lea rdx, [rbp + 0x630]
mov ecx, 0x1000
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea rdx, [rbp + 0x630]
lea rcx, [rbp - 0x70]
call fcn.1400d39f0
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
nop
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rcx, [rbp - 0x30]
call fcn.1400d4220
lea rcx, [rsp + 0x40]
call fcn.1400d4220
mov rbx, rax
lea rcx, [rbp - 0x30]
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x30]
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
lea rcx, [rbp - 0x30]
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x140115300
lea rax, [rbp - 0x30]
cmp rsi, rax
je 0x14011543f
mov rcx, rsi
call fcn.1400d4220
lea rcx, [rbp - 0x30]
call fcn.1400d4200
mov rbx, qword [rbp - 0x20]
lea rcx, [rbp - 0x30]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
mov rcx, rsi
call fcn.1400ed4d0
jmp 0x14011543f
mov r8d, 0x1000
lea rdx, [rbp + 0x630]
lea rcx, str.PATH
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
lea r8, [rbp - 0x40]
lea rdx, [0x1402ad080]
lea rcx, [rbp + 0x630]
call fcn.14023c99c
test rax, rax
je 0x140115439
nop word [rax + rax]
mov rdx, rax
lea rcx, [rbp - 0x70]
call fcn.1400d39f0
mov rbx, rax
lea rcx, [0x1402acfcc]
call fcn.1400ce070
mov rcx, rax
call fcn.1400cf110
mov r8, rax
lea rdx, [0x1402acfcc]
mov rcx, rbx
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400d3970
nop
mov rbx, qword [rbp + 8]
lea rcx, [rbp - 8]
call fcn.1400d44b0
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.140117ec0
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.1400d3970
lea rcx, [rbp - 0x30]
call fcn.1400d4220
lea rcx, [rsp + 0x40]
call fcn.1400d4220
mov rbx, rax
lea rcx, [rbp - 0x30]
call fcn.1400d4240
mov rcx, rbx
call fcn.1400d5410
lea rdx, [rsp + 0x40]
lea rcx, [rbp - 0x30]
call fcn.1400d42f0
lea rcx, [rsp + 0x40]
call fcn.1400d3900
nop
lea rcx, [rsp + 0x68]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x70]
call fcn.1400d3900
lea rcx, [rbp - 0x30]
call fcn.1400d3890
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1401152c2
lea r8, [rbp - 0x40]
lea rdx, [0x1402ad080]
mov rcx, qword [rbp - 0x40]
call fcn.14023c99c
test rax, rax
jne 0x140115340
mov r14d, 0xc0000225
mov rcx, qword [rbp + 0x20]
test rcx, rcx
jle 0x140115453
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x140115453
mov r14d, eax
lea rcx, [rbp - 8]
call fcn.1400d3900
nop
lea rcx, [rbp - 0x30]
call fcn.1400d3900
mov eax, r14d
mov rcx, qword [rbp + 0x2630]
xor rcx, rsp
call fcn.1401e3750
add rsp, 0x2748
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret