Function at 0x14001cf70
Capabilities:
Check if file exists

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xd0
mov r14, rcx
xor r13d, r13d
mov dword [rbp + 0x67], r13d
cmp qword [rcx + 0x10], r13
je 0x14001cfcf
xor r8d, r8d
mov ebx, 0x8000ffff
mov edx, ebx
lea rcx, str.PkgDefManagement_already_initialized
call fcn.140045c88
mov eax, ebx
mov rbx, qword [rsp + 0x118]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
lea r15, [rcx + 0x58]
or edi, 0xffffffff
test rdx, rdx
je 0x14001d093
lea rcx, [rbp - 0x79]
call fcn.140002f00
nop
lea rdx, [rbp - 0x79]
mov rcx, r15
call fcn.1400068a0
nop
mov rdx, qword [rbp - 0x79]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d017
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rcx, qword [r15]
sub rcx, 0x18
call fcn.140002a70
add rax, 0x18
mov qword [rsp + 0x28], rax
lea rcx, [rsp + 0x28]
call fcn.14002a590
mov esi, eax
test eax, eax
jns 0x14001d261
call fcn.140002950
test rax, rax
je 0x14001d9b2
lfence
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
add rax, 0x18
mov qword [rbp - 0x49], rax
mov rcx, qword [r15]
mov r12d, 4
test rcx, rcx
je 0x14001d1bd
add rcx, 0xffffffffffffffe8
call fcn.140002a70
lea r8, [rax + 0x18]
mov qword [rbp - 0x51], r8
mov ebx, r12d
mov r15d, r13d
mov r14d, r12d
jmp 0x14001d1dd
mov rcx, r15
call fcn.140013bcc
mov esi, eax
test eax, eax
jns 0x14001d017
call fcn.140002950
mov rcx, rax
test rax, rax
je 0x14001d9cf
lfence
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp - 0x61], rax
mov r12d, 1
cmp qword [r15], r13
je 0x14001d0f4
lfence
mov rcx, qword [r15]
sub rcx, 0x18
call fcn.140002a70
lea r8, [rax + 0x18]
mov qword [rbp - 0x69], r8
mov ebx, r12d
mov r15d, r13d
mov r14d, r12d
jmp 0x14001d113
lea rdx, str.NULL
lea rcx, [rbp - 0x71]
call fcn.140002f00
mov ebx, 2
mov r8, qword [rbp - 0x71]
mov r15d, ebx
mov r14d, r13d
mov dword [rbp + 0x67], ebx
lea rdx, str.DiscoverHostingAppPath_failed_for_executable_path:__s
lea rcx, [rbp - 0x61]
call fcn.14001d9e0
or edi, 0xffffffff
test r15d, r15d
je 0x14001d158
nop
mov dword [rbp + 0x67], r14d
mov rdx, qword [rbp - 0x71]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d155
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov ebx, dword [rbp + 0x67]
test r12b, bl
je 0x14001d184
and ebx, 0xfffffffe
mov dword [rbp + 0x67], ebx
mov rdx, qword [rbp - 0x69]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d184
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
xor r8d, r8d
mov edx, esi
mov rbx, qword [rbp - 0x61]
mov rcx, rbx
call fcn.140045c88
nop
lea rdx, [rbx - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d1b3
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
lfence
mov eax, esi
jmp 0x14001cfb4
lea rdx, str.NULL
lea rcx, [rbp - 0x59]
call fcn.140002f00
nop
mov ebx, 8
mov r8, qword [rbp - 0x59]
mov r15d, ebx
mov r14d, r13d
mov dword [rbp + 0x67], ebx
lea rdx, str.GetCanonicalName_failed_for_application_executable_path__s
lea rcx, [rbp - 0x49]
call fcn.14001d9e0
nop
test r15d, r15d
je 0x14001d21e
mov dword [rbp + 0x67], r14d
mov rdx, qword [rbp - 0x59]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d21b
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov ebx, dword [rbp + 0x67]
test r12b, bl
je 0x14001d24a
and ebx, 0xfffffffb
mov dword [rbp + 0x67], ebx
mov rdx, qword [rbp - 0x51]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d24a
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
xor r8d, r8d
mov edx, esi
mov rbx, qword [rbp - 0x49]
mov rcx, rbx
call fcn.140045c88
nop
jmp 0x14001d5b9
mov rdx, qword [rsp + 0x28]
lea rcx, [rbp - 0x41]
call fcn.140002f00
nop
lea rdx, [rbp - 0x41]
mov rcx, r15
call fcn.1400068a0
nop
mov rdx, qword [rbp - 0x41]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d29e
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rcx, qword [r15]
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
lea r12, [r14 + 0x190]
mov rsi, qword [r15]
test eax, eax
je 0x14001d5df
test rsi, rsi
jne 0x14001d2c8
mov esi, 0x80070057
jmp 0x14001d4da
lea rdx, [0x140067c00]
lea rcx, [rbp - 0x39]
call fcn.140002f00
nop
lea rdx, [rbp - 0x39]
mov rcx, r12
call fcn.1400068a0
nop
mov rdx, qword [rbp - 0x39]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d307
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov qword [rbp + 0x77], r13
mov rdx, rsi
lea rcx, [rbp + 0x77]
call fcn.140002f00
nop
mov rcx, qword [rbp + 0x77]
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x14001d33a
mov r8, rsi
mov esi, 0x80070057
lea rcx, str.AppId_path_is_not_a_directory
jmp 0x14001d4b1
lea rdx, str.master.pkgdef
lea rcx, [rbp + 0x77]
call fcn.14000a324
mov rcx, qword [rbp + 0x77]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x14001d36e
lea rdx, [rbp + 0x77]
mov rcx, r12
call fcn.1400068a0
nop
mov rdx, qword [rbp + 0x77]
jmp 0x14001d8fb
mov rdx, rsi
lea rcx, [rbp - 0x31]
call fcn.140002f00
lea rdx, [rbp - 0x31]
lea rcx, [rbp + 0x77]
call fcn.1400068a0
mov rdx, qword [rbp - 0x31]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d3a8
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
lea rdx, str.devenv.pkgdef
lea rcx, [rbp + 0x77]
call fcn.14000a324
mov rcx, qword [rbp + 0x77]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14001d358
mov rdx, rsi
lea rcx, [rbp - 0x29]
call fcn.140002f00
nop
lea rdx, [rbp - 0x29]
lea rcx, [rbp + 0x77]
call fcn.1400068a0
nop
mov rdx, qword [rbp - 0x29]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d402
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
lea rdx, [0x1400798b0]
lea rcx, [rbp + 0x77]
call fcn.14000a324
lea rdx, str.master.pkgdef
lea rcx, [rbp + 0x77]
call fcn.14000a324
mov rcx, qword [rbp + 0x77]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14001d358
mov rdx, rsi
lea rcx, [rbp - 0x21]
call fcn.140002f00
nop
lea rdx, [rbp - 0x21]
lea rcx, [rbp + 0x77]
call fcn.1400068a0
nop
mov rdx, qword [rbp - 0x21]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d470
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
lea rdx, [0x1400798b0]
lea rcx, [rbp + 0x77]
call fcn.14000a324
lea rdx, str.devenv.pkgdef
lea rcx, [rbp + 0x77]
call fcn.14000a324
mov rcx, qword [rbp + 0x77]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14001d358
mov r8, rsi
mov esi, 0x80030002
lea rcx, str.Could_not_locate_master_pkgdef_file_in_directory
mov edx, esi
call fcn.140045c88
nop
mov rdx, qword [rbp + 0x77]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d4da
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
call fcn.140002950
mov rcx, rax
test rax, rax
je 0x14001d9b2
lfence
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp - 9], rax
mov rcx, qword [r15]
mov r15d, reloc.OLEAUT32.dll_SafeArrayGetDim
test rcx, rcx
je 0x14001d527
add rcx, 0xffffffffffffffe8
call fcn.140002a70
lea r8, [rax + 0x18]
mov qword [rbp - 0x11], r8
mov dword [rbp + 0x67], r15d
mov ebx, r13d
mov r14d, r15d
jmp 0x14001d546
lea rdx, str.NULL
lea rcx, [rbp - 0x19]
call fcn.140002f00
mov ebx, SafeArrayAllocDescriptor
mov dword [rbp + 0x67], ebx
mov r8, qword [rbp - 0x19]
mov r14d, r13d
lea rdx, str.LocateMasterPkgDefInDirectory_failed_for_app_executable_path__s
lea rcx, [rbp - 9]
call fcn.14001d9e0
test ebx, ebx
je 0x14001d580
mov dword [rbp + 0x67], r14d
mov rdx, qword [rbp - 0x19]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d580
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
test byte [rbp + 0x67], r15b
je 0x14001d5a7
mov rdx, qword [rbp - 0x11]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d5a7
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
xor r8d, r8d
mov edx, esi
mov rbx, qword [rbp - 9]
mov rcx, rbx
call fcn.140045c88
nop
lea rdx, [rbx - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d987
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
jmp 0x14001d987
test rsi, rsi
jne 0x14001d5ee
mov esi, 0x80070057
jmp 0x14001d7e8
mov qword [rbp + 0x7f], r13
mov rdx, rsi
lea rcx, [rbp + 0x7f]
call fcn.140002f00
nop
lea rdx, [0x140067c00]
lea rcx, [rbp - 1]
call fcn.140002f00
nop
lea rdx, [rbp - 1]
mov rcx, r12
call fcn.1400068a0
nop
mov rdx, qword [rbp - 1]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d63e
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rcx, qword [rbp + 0x7f]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14001d668
mov esi, 0x80030002
lea rcx, str.Could_not_locate_executable
mov edx, esi
mov r8, qword [rbp + 0x7f]
call fcn.140045c88
jmp 0x14001d7c7
lea rdx, [rbp + 0x1f]
lea rcx, [rbp + 0x7f]
call fcn.1400132fc
mov rbx, rax
mov rcx, qword [rax]
movsxd r13, dword [rcx - 0x10]
test r13d, r13d
js 0x14001d9c0
lfence
mov rcx, qword [rax]
mov r8d, 1
sub r8d, dword [rcx - 8]
mov edx, dword [rcx - 0xc]
sub edx, r13d
or edx, r8d
jge 0x14001d6b1
lfence
mov edx, r13d
mov rcx, rax
call fcn.140002d40
lea eax, [r13 + 1]
movsxd rdx, eax
mov rcx, qword [rbx]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsupr_s]
mov rax, qword [rbx]
cmp r13d, dword [rax - 0xc]
jg 0x14001d9c0
mov dword [rax - 0x10], r13d
mov rcx, r13
mov rax, qword [rbx]
xor r13d, r13d
mov word [rax + rcx*2], r13w
lea rdx, str..EXE
mov rcx, qword [rbx]
call sub.api_ms_win_crt_string_l1_1_0.dll_wcscmp
mov ebx, eax
mov rdx, qword [rbp + 0x1f]
add rdx, 0xffffffffffffffe8
mov ecx, edi
lock xadd dword [rdx + 0x10], ecx
add ecx, edi
test ecx, ecx
jg 0x14001d713
lfence
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [rreloc.OLEAUT32.dll_VariantClear + 8]
test ebx, ebx
je 0x14001d728
mov esi, 0x80070057
lea rcx, str.Executable_is_not_.EXE
jmp 0x14001d658
mov rcx, qword [rbp + 0x7f]
add rcx, 0xffffffffffffffe8
call fcn.140002a70
add rax, 0x18
mov qword [rsp + 0x20], rax
lea rdx, str..PkgDef
lea rcx, [rsp + 0x20]
call fcn.14002a4f0
mov rbx, qword [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14001d781
lea rcx, [rsp + 0x20]
call fcn.140022420
lea rdx, str.master.pkgdef
lea rcx, [rsp + 0x20]
call fcn.14000a324
mov rbx, qword [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14001d8cc
mov r8, rsi
mov esi, 0x80030002
mov edx, esi
lea rcx, str.Could_not_locate_master_pkgdef_file_for_AppId
call fcn.140045c88
nop
lea rdx, [rbx - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d7c7
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp + 0x7f]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d7e8
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
call fcn.140002950
mov rcx, rax
test rax, rax
je 0x14001d9b2
lfence
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp + 0x17], rax
mov rcx, qword [r15]
mov r15d, 0x40
test rcx, rcx
je 0x14001d835
add rcx, 0xffffffffffffffe8
call fcn.140002a70
lea r8, [rax + 0x18]
mov qword [rbp + 0xf], r8
mov dword [rbp + 0x67], r15d
mov ebx, r13d
mov r14d, r15d
jmp 0x14001d854
lea rdx, str.NULL
lea rcx, [rbp + 7]
call fcn.140002f00
mov ebx, 0x80
mov dword [rbp + 0x67], ebx
mov r8, qword [rbp + 7]
mov r14d, r13d
lea rdx, str.LocateMasterPkgDefFromExe_failed_for_app_executable_path__s
lea rcx, [rbp + 0x17]
call fcn.14001d9e0
test ebx, ebx
je 0x14001d88e
mov dword [rbp + 0x67], r14d
mov rdx, qword [rbp + 7]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d88e
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
test byte [rbp + 0x67], r15b
je 0x14001d8b5
mov rdx, qword [rbp + 0xf]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d8b5
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
xor r8d, r8d
mov edx, esi
mov rbx, qword [rbp + 0x17]
mov rcx, rbx
call fcn.140045c88
nop
jmp 0x14001d5b9
lea rdx, [rsp + 0x20]
mov rcx, r12
call fcn.1400068a0
lea rdx, [rbx - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d8f7
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp + 0x7f]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d918
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov esi, r13d
mov rdx, r12
lea rcx, [r14 + 0x50]
call fcn.1400068a0
lea rcx, [r14 + 0x50]
call fcn.140022420
mov ebx, SafeArrayAllocDescriptor
test byte [r14 + 0x3c], bl
jne 0x14001d955
test dword [r14 + 0x3c], 0x2000
jne 0x14001d955
cmp dword [r14 + 0x44], edi
je 0x14001d955
mov rax, qword [r14 + 0x78]
cmp dword [rax - 0x10], r13d
je 0x14001d987
mov rcx, r14
call fcn.140017990
mov esi, eax
test eax, eax
jns 0x14001d979
lfence
xor r8d, r8d
mov edx, eax
lea rcx, str.ScanMasterPkgDefForInitializationFields_failed
call fcn.140045c88
jmp 0x14001d987
cmp dword [r14 + 0x44], edi
jne 0x14001d987
mov dword [r14 + 0x44], 1
mov rdx, qword [rsp + 0x28]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
add eax, edi
test eax, eax
jg 0x14001d1b6
lfence
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
jmp 0x14001d1b6
mov ecx, 0x80004005
call fcn.1400327c0
nop
jmp 0x14001d9bf
nop
mov ecx, 0x80070057
call fcn.1400327c0
nop
jmp 0x14001d9ce
nop
mov ecx, 0x80004005
call fcn.1400327c0
int3