Function at 0x140001660
Capabilities:
Accept command line arguments
Check if file exists
Get file attributes
Get file version info
Query environment variable
Set environment variable

Disassembly:
push rbx
push rdi
mov eax, 0x1888
call fcn.14001b8e0
sub rsp, rax
mov rax, qword [0x14002a008]
xor rax, rsp
mov qword [rsp + 0x1860], rax
mov ecx, 2
call fcn.14000c158
xor r9d, r9d
mov rcx, rax
xor edx, edx
lea r8d, [r9 + 4]
call fcn.14000d240
lea rbx, [0x140045dd0]
mov r8d, 0x100
mov rdx, rbx
lea rcx, str.PYLAUNCH_DEBUG
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
cmp eax, 0x100
jb 0x1400016fb
lea ecx, [rax + 1]
add rcx, rcx
call fcn.14000d464
mov rbx, rax
test rax, rax
jne 0x1400016e6
lea rdx, str.Could_not_allocate_environment_buffer
lea ecx, [rax + 0x68]
call fcn.1400011d0
int3
mov r8d, edi
lea rcx, str.PYLAUNCH_DEBUG
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
jmp 0x1400016ff
test edi, edi
je 0x140001716
cmp word [rbx], 0
je 0x140001716
mov ecx, 2
call fcn.14000c158
mov qword [0x14002bfb8], rax
lea rcx, str.launcher_build:_64bit_n
call fcn.140001130
lea rcx, str.launcher_executable:_Console_n
call fcn.140001130
mov ebx, 0x104
mov ecx, ebx
add rcx, rcx
call fcn.14000d464
mov rdi, rax
test rax, rax
je 0x140001cce
mov r8d, ebx
mov rdx, rax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x140001cb7
cmp eax, ebx
jne 0x14000177a
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x14000177a
mov rcx, rdi
call fcn.14000d378
add ebx, ebx
jmp 0x140001733
mov qword [rsp + 0x18b0], r12
lea rdx, [rsp + 0x40]
mov qword [rsp + 0x1880], r13
mov rcx, rdi
mov qword [rsp + 0x1878], r14
call qword [sym.imp.VERSION.dll_GetFileVersionInfoSizeW]
xor r13d, r13d
mov dword [rsp + 0x40], eax
test eax, eax
jne 0x1400017f4
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [rsp + 0x60]
mov qword [rsp + 0x30], r13
mov dword [rsp + 0x28], 0x400
mov r9d, 0x400
mov qword [rsp + 0x20], rcx
mov r8d, eax
mov ecx, 0x1200
xor edx, edx
call qword [sym.imp.KERNEL32.dll_FormatMessageW]
lea rdx, [rsp + 0x60]
lea rcx, str.GetFileVersionInfoSize_failed:__ls_n
call fcn.140001130
jmp 0x140001887
mov ecx, eax
call fcn.14000d464
mov rbx, rax
test rax, rax
je 0x140001887
mov r8d, dword [rsp + 0x40]
mov r9, rax
xor edx, edx
mov rcx, rdi
call qword [sym.imp.VERSION.dll_GetFileVersionInfoW]
test eax, eax
jne 0x140001834
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.GetFileVersionInfo_failed:__X_n
call fcn.140001130
jmp 0x14000187f
lea r9, [rsp + 0x50]
mov rcx, rbx
lea r8, [rsp + 0x58]
lea rdx, [0x14002580c]
call qword [sym.imp.VERSION.dll_VerQueryValueW]
test eax, eax
jne 0x140001868
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.VerQueryValue_failed:__X_n
call fcn.140001130
jmp 0x14000187f
mov rcx, qword [rsp + 0x58]
mov eax, dword [rcx + 8]
mov dword [0x140045fd8], eax
mov eax, dword [rcx + 0xc]
mov dword [0x140045fdc], eax
mov rcx, rbx
call fcn.14000d378
mov r14, 0xffffffffffffffff
mov rbx, r14
inc rbx
cmp word [rdi + rbx*2], r13w
jne 0x140001891
add rbx, 0x21
lea rcx, [rbx + rbx]
call fcn.14000d464
mov r12, rax
test rax, rax
je 0x1400018ca
mov r8, rdi
mov rdx, rbx
mov rcx, rax
call fcn.14000c908
mov rcx, r12
test eax, eax
je 0x1400018dc
call fcn.14000d378
lea rdx, str.Failed_to_copy_module_name
mov ecx, 0x68
call fcn.1400011d0
int3
mov qword [rsp + 0x18a0], rbp
mov ebp, 0x5c
mov qword [rsp + 0x18a8], rsi
mov edx, ebp
mov esi, 0x7fffffff
cmp rbx, rsi
cmovb esi, ebx
call fcn.140002bd4
mov rbx, rax
test rax, rax
jne 0x14000191b
lea rdx, str.No_pyvenv.cfg_file
lea ecx, [rbp + 0xe]
call fcn.1400011d0
int3
movsxd rsi, esi
lea r8, str.pyvenv.cfg
mov rdx, rsi
mov word [rax], r13w
mov rcx, r12
call fcn.14000c970
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1400019a9
mov rdx, r12
lea rcx, str.File__ls_non_existent_n
call fcn.140001130
mov edx, ebp
mov word [rbx], r13w
mov rcx, r12
call fcn.140002bd4
test rax, rax
je 0x1400019a9
lea r8, str.pyvenv.cfg
mov word [rax], r13w
mov rdx, rsi
mov rcx, r12
call fcn.14000c970
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1400019a9
mov rdx, r12
lea rcx, str.File__ls_non_existent_n
call fcn.140001130
lea rdx, str.No_pyvenv.cfg_file
mov ecx, 0x6a
call fcn.1400011d0
int3
mov rdx, r12
mov qword [rsp + 0x1870], r15
lea rcx, str.Using_venv_configuration_file__ls_n
call fcn.140001130
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov rcx, rax
movzx edx, word [rax]
cmp dx, 0x22
jne 0x1400019d6
add rcx, 2
mov r8d, 0x22
mov eax, 0x20
cmp dx, r8w
cmove ax, r8w
movzx edx, ax
call fcn.1400028e0
test rax, rax
jne 0x140001a00
lea r15, [0x140025c20]
jmp 0x140001a2a
lea r15, [rax + 2]
movzx eax, word [rax + 2]
test ax, ax
je 0x140001a2a
nop dword [rax]
movzx ecx, ax
call fcn.14000d390
test eax, eax
je 0x140001a2a
movzx eax, word [r15 + 2]
add r15, 2
test ax, ax
jne 0x140001a10
mov rdx, r15
lea rcx, str.Called_with_command_line:__ls_n
call fcn.140001130
lea r8, [0x140025f20]
mov rdx, r12
lea rcx, [rsp + 0x48]
call fcn.14000c68c
test eax, eax
je 0x140001a66
mov r8, r12
lea rdx, str.Cannot_read__ls
mov ecx, 0x6b
call fcn.1400011d0
int3
mov rax, qword [rsp + 0x48]
lea rcx, [rsp + 0x860]
mov edx, 0x1000
mov qword [rsp + 0x20], rax
mov r9d, edx
mov r8d, 1
call fcn.14000d070
mov rcx, qword [rsp + 0x48]
call fcn.14000c804
lea rdx, str.home
lea rcx, [rsp + 0x860]
call fcn.14000295c
mov rbx, rax
test rax, rax
je 0x140001b09
cmp byte [rbx], 0xa
jne 0x140001ab9
inc rbx
mov eax, 4
nop
cmp byte [rbx], r13b
je 0x140001aec
dec eax
inc rbx
test eax, eax
jg 0x140001ac0
cmp byte [rbx], r13b
je 0x140001aec
movsx ecx, byte [rbx]
mov edx, 8
call fcn.14000c89c
test eax, eax
je 0x140001aec
inc rbx
cmp byte [rbx], r13b
jne 0x140001ad3
cmp byte [rbx], 0x3d
je 0x140001b20
lea rcx, [rbx + 1]
lea rdx, str._nhome
call fcn.14000295c
mov rbx, rax
test rax, rax
jne 0x140001ab1
mov r8, r12
lea rdx, str.Cannot_find_home_in__ls
mov ecx, 0x6b
call fcn.1400011d0
int3
movsx eax, byte [rbx + 1]
inc rbx
mov esi, ebx
test al, al
je 0x140001b3e
mov edx, 8
movzx ecx, ax
call fcn.14000c89c
test eax, eax
jne 0x140001b20
mov edx, 0xa
mov rcx, rbx
call fcn.140002b54
mov rbp, rax
test rax, rax
je 0x140001b57
sub ebp, esi
jmp 0x140001b63
inc r14
cmp byte [rbx + r14], r13b
jne 0x140001b57
mov ebp, r14d
mov dword [rsp + 0x28], r13d
mov r9d, ebp
mov r8, rbx
mov qword [rsp + 0x20], r13
xor edx, edx
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov r14d, eax
test eax, eax
jne 0x140001b96
lea rdx, str.Cannot_determine_memory_for_home_path
xor ecx, ecx
call fcn.1400011d0
int3
add r14d, 0xe
lea rcx, [r14 + r14]
call fcn.14000d464
mov rsi, rax
test rax, rax
jne 0x140001bbb
lea rdx, str.A_memory_allocation_failed
lea ecx, [rax + 0x68]
call fcn.1400011d0
int3
mov eax, 0x22
lea r13, [rsi + 2]
mov word [rsi], ax
mov r9d, ebp
lea eax, [r14 - 1]
mov r8, rbx
mov dword [rsp + 0x28], eax
xor edx, edx
mov ecx, 0xfde9
mov qword [rsp + 0x20], r13
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, eax
mov r8d, eax
test eax, eax
jne 0x140001c03
mov r8, r12
lea rdx, str.Cannot_decode_home_path_in__ls
lea ecx, [rax + 0x6b]
call fcn.1400011d0
int3
inc ecx
xor r9d, r9d
cmp word [rsi + r8*2], 0x5c
lea rdx, [rsi + rcx*2]
mov word [rdx], r9w
je 0x140001c27
inc ecx
mov eax, 0x5c
mov word [rdx], ax
mov word [rsi + rcx*2], r9w
lea edx, [r14 - 1]
mov rcx, r13
lea r8, str.python.exe
call fcn.14000c970
test eax, eax
je 0x140001c53
mov r8, r12
lea rdx, str.Cannot_create_executable_path_from__ls
mov ecx, 0x6b
call fcn.1400011d0
int3
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x140001c76
mov r8, rsi
lea rdx, str.No_Python_at__ls
mov ecx, 0x67
call fcn.1400011d0
int3
lea r8, [0x1400260f0]
mov edx, r14d
mov rcx, rsi
call fcn.14000c970
mov rdx, rdi
lea rcx, str.__PYVENV_LAUNCHER__
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
test eax, eax
jne 0x140001cab
lea rdx, str.Failed_to_set_launcher_environment
xor ecx, ecx
call fcn.1400011d0
int3
mov r8, r15
mov rcx, rsi
call fcn.1400015b0
int3
mov rcx, rdi
call fcn.14000d378
lea rdx, str.Failed_to_get_module_name
xor ecx, ecx
call fcn.1400011d0
int3
lea rdx, str.out_of_memory
mov ecx, 0x68
call fcn.1400011d0
int3