Function at 0x140020194
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r14
push r15
lea rbp, [rsp - 0x360]
sub rsp, 0x460
mov rax, qword [0x1400502a8]
xor rax, rsp
mov qword [rbp + 0x350], rax
mov r14, rcx
mov rsi, rdx
mov ecx, 0xc8
call fcn.14003c2c4
xor r15d, r15d
test rax, rax
je 0x1400201e5
mov rcx, rax
call fcn.14001df2c
mov rbx, rax
jmp 0x1400201e8
mov rbx, r15
test rbx, rbx
jne 0x1400201f7
mov eax, 0x8007000e
jmp 0x1400204a8
lea r8, [rsp + 0x30]
mov dword [rsp + 0x20], r15d
lea rdx, str.INSTALLTYPE
mov rcx, rsi
call fcn.14001c1c8
mov edi, eax
test eax, eax
jns 0x140020233
lea r8, str.INSTALLTYPE
lea rdx, str.ERROR:_Reg_Parser:_Missing_required_Package_attribute__S._r_n
mov ecx, 2
call fcn.140016868
jmp 0x140020482
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.14001e488
cmp dword [rbx + 0x58], 1
jne 0x140020283
lea r8, [rsp + 0x30]
mov dword [rsp + 0x20], r15d
lea rdx, str.UPDATEEXE
mov rcx, rsi
call fcn.14001c1c8
test eax, eax
js 0x140020283
lea rdx, [0x1400453f8]
lea rcx, [rsp + 0x30]
call qword [sym.imp.msvcrt.dll__wcsicmp]
mov ecx, r15d
test eax, eax
sete cl
mov dword [rbx + 0x90], ecx
lea r8, [rsp + 0x30]
mov dword [rsp + 0x20], r15d
lea rdx, str.INSTALLFILE
mov rcx, rsi
call fcn.14001c1c8
mov edi, eax
test eax, eax
jns 0x1400202ae
lea r8, str.INSTALLFILE
jmp 0x14002021d
cmp dword [rbx + 0x58], 1
je 0x14002034e
mov edi, 0x104
lea rcx, [rbp + 0x140]
mov edx, edi
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
je 0x14002030f
lea rcx, [rbp + 0x140]
or rax, 0xffffffffffffffff
inc rax
cmp word [rcx + rax*2], r15w
jne 0x1400202db
sub rdi, rax
lea r9, [rbp + 0x140]
lea rax, [rsp + 0x30]
mov rdx, rdi
lea r8, str._sinf_s
mov qword [rsp + 0x20], rax
lea rcx, [rbp + 0x140]
call fcn.140001734
lea rcx, [rbp + 0x140]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x14002032e
test al, 0x10
jne 0x14002032e
lea rdx, [rbp + 0x140]
jmp 0x140020353
mov edi, 1
lea r8, str.INSTALLFILE
lea rdx, str.ERROR:_Setup_missing_uninstall_file:__S._r_n
lea ecx, [rdi + 1]
call fcn.140016868
jmp 0x140020486
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.14001e554
lea r8, [rsp + 0x30]
mov dword [rsp + 0x20], r15d
lea rdx, str.UNINSTALL
mov rcx, rsi
call fcn.14001c1c8
mov edi, eax
test eax, eax
jns 0x140020386
lea r8, str.UNINSTALL
jmp 0x14002021d
lea rdx, [0x1400453f8]
lea rcx, [rsp + 0x30]
call qword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
jne 0x1400203a5
mov dword [rbx + 0x8c], r15d
jmp 0x1400203c7
lea rdx, [0x1400450f8]
lea rcx, [rsp + 0x30]
call qword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
mov ecx, r15d
setne cl
inc ecx
mov dword [rbx + 0x8c], ecx
lea r8, [rsp + 0x30]
mov dword [rsp + 0x20], r15d
lea rdx, str.MOREINSTALLINFO
mov rcx, rsi
call fcn.14001c1c8
test eax, eax
js 0x140020456
lea rdi, [rbx + 0x28]
test rdi, rdi
je 0x140020456
mov rcx, qword [rdi]
test rcx, rcx
je 0x1400203fd
call fcn.14003c2b8
mov qword [rdi], r15
or rcx, 0xffffffffffffffff
lea rax, [rsp + 0x30]
mov rsi, rcx
inc rsi
cmp word [rax + rsi*2], r15w
jne 0x140020409
inc rsi
mov eax, 2
mul rsi
cmovo rax, rcx
mov rcx, rax
call fcn.14003c310
mov qword [rdi], rax
test rax, rax
je 0x140020456
lea r8, [rsp + 0x30]
mov rdx, rsi
mov rcx, rax
call fcn.140001470
test eax, eax
jns 0x140020456
mov rcx, qword [rdi]
test rcx, rcx
je 0x140020456
call fcn.14003c2b8
mov qword [rdi], r15
cmp qword [rbx + 8], r15
jne 0x140020462
cmp qword [rbx + 0x18], r15
je 0x14002047d
cmp dword [rbx + 0x8c], 2
je 0x14002047d
xor r8d, r8d
mov rdx, rbx
mov rcx, r14
call fcn.14002010c
mov edi, eax
jmp 0x140020482
mov edi, 1
test edi, edi
je 0x1400204a6
mov rcx, rbx
call fcn.14001ffb4
test edi, edi
jns 0x1400204a6
mov r8d, edi
lea rdx, str.ERROR:_Reg_Parser:_Failed_to_add_uninstall_information_from_reg.__Last_result:_0x_x._r_n
mov ecx, 2
call fcn.140016868
mov eax, edi
mov rcx, qword [rbp + 0x350]
xor rcx, rsp
call fcn.14003c6c0
mov rbx, qword [rsp + 0x4a0]
add rsp, 0x460
pop r15
pop r14
pop rdi
pop rsi
pop rbp
ret