Function at 0x405ae0
Capabilities:
Accept command line arguments
Extract resource via kernel32 functions
Query environment variable

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x10064
call fcn.004220f0
mov eax, dword [section..data]
xor eax, esp
mov dword [esp + 0x10060], eax
push ebx
push esi
push edi
push 0x48
lea eax, [esp + 0x24]
mov ebx, edx
push 0
push eax
mov dword [esp + 0x24], ebx
call fcn.00407660
add esp, 0xc
lea eax, [esp + 0x68]
xor ecx, ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x1c], ecx
push 0x10000
push ecx
push eax
call fcn.00407660
mov edi, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
add esp, 0xc
push 0
push 0
push str.PYLAUNCHER_DEBUG
call edi
cmp eax, 2
jb 0x405b84
push 0
push 4
push 0
push 2
call fcn.0040ef6d
add esp, 4
push eax
call fcn.00415291
push 2
call fcn.0040ef6d
add esp, 0x14
mov dword [0x42f5d0], eax
push 0x42b7b8
push dword [ebx]
push str.argv0:__s_nversion:__S_n
call fcn.00401130
add esp, 0xc
push 0
push 0
push str.PYLAUNCHER_LIMIT_TO_COMPANY
call edi
mov esi, eax
cmp esi, 1
jbe 0x405bdd
lea ecx, [esi*2 + 4]
push ecx
call fcn.004153ae
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x405bb9
mov eax, dword [esp + 0x64]
mov dword [ecx], eax
mov dword [esp + 0x64], ecx
add ecx, 4
push esi
push ecx
push str.PYLAUNCHER_LIMIT_TO_COMPANY
mov dword [esp + 0x6c], ecx
call edi
test eax, eax
jne 0x405bdd
push str.Failed_to_read_PYLAUNCHER_LIMIT_TO_COMPANY_variable
push eax
lea edi, [eax + 0x6d]
call fcn.00401200
jmp 0x406502
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], eax
call fcn.00401770
mov edi, eax
test edi, edi
jne 0x406505
lea ecx, [esp + 0x20]
call fcn.00402910
mov edi, eax
sub eax, 0
je 0x405c14
sub eax, 0x71
je 0x405c14
sub eax, 1
jne 0x405c3f
lea ecx, [esp + 0x20]
call fcn.00402f40
mov edi, eax
test edi, edi
jne 0x406505
lea ecx, [esp + 0x20]
call fcn.00401450
lea edx, [esp + 0x10]
lea ecx, [esp + 0x20]
call fcn.004046e0
mov edi, eax
test edi, edi
jne 0x406505
cmp byte [esp + 0x5c], 0
je 0x405d46
push edi
push 1
push 0x428fd0
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceExW]
mov esi, eax
test esi, esi
je 0x405d5a
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x405d5a
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
test ebx, ebx
je 0x405d5a
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
push edi
push eax
push ebx
push edi
push 0xfde9
mov dword [esp + 0x2c], eax
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov edi, eax
test edi, edi
jne 0x405cc3
push str.Unable_to_preprocess_usage_text
push eax
call fcn.00401200
mov edi, 0x6d
jmp 0x406502
inc edi
lea eax, [edi + edi]
push eax
call fcn.004153ae
add esp, 4
mov esi, eax
push edi
push esi
push dword [esp + 0x1c]
push ebx
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x405d08
push str.Unable_to_preprocess_usage_text
push eax
call fcn.00401200
push esi
call fcn.004152cb
add esp, 0xc
mov edi, 0x6d
jmp 0x406505
xor ecx, ecx
mov word [esi + eax*2], cx
mov eax, dword [esp + 0x18]
push dword [eax]
push 0x429050
push esi
push 1
call fcn.0040ef6d
add esp, 4
push eax
call fcn.00401020
push 1
call fcn.0040ef6d
add esp, 0x14
push eax
call fcn.0040f301
add esp, 4
push esi
call fcn.004152cb
add esp, 4
mov edi, dword [esp + 0x10]
test edi, edi
jne 0x405d70
mov dword [esp + 0x1c], edi
lea ebx, [edi + 0x70]
jmp 0x405e5c
push str.Unable_to_load_usage_text
push 0
call fcn.00401200
mov edi, 0x6d
jmp 0x406502
mov dword [esp + 0x18], 0
mov esi, edi
nop word [eax + eax]
mov edx, dword [esi]
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x24]
call fcn.00404ff0
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x405da4
cmp ebx, 0x67
jne 0x405e58
jmp 0x405db0
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x405e52
cmp byte [esi + 0x2c], 0
je 0x405dc1
cmp byte [esp + 0x55], 0
jne 0x405e50
cmp byte [esp + 0x54], 0
jne 0x405eb0
mov edi, dword [esp + 0x44]
test edi, edi
je 0x405e38
mov ebx, dword [esp + 0x48]
test ebx, ebx
je 0x405e38
mov eax, dword [esi + 0xc]
mov dword [esp + 0x14], eax
test eax, eax
je 0x405e2d
push 0
push 0
push 0
push ebx
push edi
push 0xffffffffffffffff
push eax
push 9
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x405e2d
sub eax, 1
je 0x405eac
sub eax, 1
je 0x405ea5
push edi
push ebx
push dword [esp + 0x1c]
push 0xffffffffffffffff
push str.Error_comparing__.s_and__.s__compare_
push 0
call fcn.00401200
add esp, 0x18
or eax, 0xffffffff
test eax, eax
jne 0x406035
push 0xffffffffffffffff
mov edx, esi
lea ecx, [esp + 0x24]
call fcn.00404e40
add esp, 4
test al, al
je 0x406035
mov eax, esi
xor ebx, ebx
mov dword [esp + 0x1c], eax
mov edi, dword [esp + 0x10]
cmp byte [esp + 0x5a], 0
jne 0x40648a
cmp byte [esp + 0x5b], 0
jne 0x40648a
mov esi, dword [0x42f5d0]
test esi, esi
je 0x40609b
test edi, edi
jne 0x406048
push str.No_installed_Pythons_found__n
push 1
call fcn.0040ef6d
add esp, 4
push eax
call fcn.00401050
add esp, 8
jmp 0x40609b
mov eax, 1
jmp 0x405e30
xor eax, eax
jmp 0x405e30
mov edi, dword [esi + 0xc]
test edi, edi
je 0x406035
push 0
push 0
push 0
push 0xffffffffffffffff
push str.PythonCore
push 0xffffffffffffffff
push edi
push 9
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x406035
sub eax, 1
je 0x405f0d
sub eax, 1
je 0x406035
push str.PythonCore
push 0xffffffffffffffff
push edi
push 0xffffffffffffffff
push str.Error_comparing__.s_and__.s__compare_
push 0
call fcn.00401200
add esp, 0x18
jmp 0x406035
mov ebx, dword [esp + 0x50]
mov byte [esp + 0xe], 0
mov byte [esp + 0xf], 0
cmp ebx, 3
jle 0x405fd6
mov eax, dword [esp + 0x4c]
lea ecx, [ebx - 3]
mov dword [esp + 0x14], ecx
lea edi, [eax + ecx*2]
test edi, edi
je 0x405fd6
push 0
push 0
push 0
push 3
push 0x42b210
push 3
push edi
push 0
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x405f7f
sub eax, 1
je 0x405fc6
sub eax, 1
je 0x405f7f
push 0x42b210
push 3
push edi
push 3
push str.Error_comparing__.s_and__.s__compareArgument_
push 0
call fcn.00401200
add esp, 0x18
push 0
push 0
push 0
push 3
push 0x429eb0
push 3
push edi
push 0
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x405fd6
sub eax, 1
je 0x405fcd
sub eax, 1
je 0x405fd6
push 0x429eb0
push 3
push edi
push 3
push str.Error_comparing__.s_and__.s__compareArgument_
push 0
call fcn.00401200
add esp, 0x18
jmp 0x405fd6
mov byte [esp + 0xe], 1
jmp 0x405fd2
mov byte [esp + 0xf], 1
mov ebx, dword [esp + 0x14]
push ebx
mov edx, esi
lea ecx, [esp + 0x24]
call fcn.00404e40
add esp, 4
test al, al
je 0x406035
cmp byte [esp + 0xe], 0
je 0x406008
mov ecx, esi
call fcn.00404f80
test al, al
je 0x406008
push dword [esi + 0x10]
push dword [esi + 0xc]
push str._Excluding__s__s_because_it_looks_like_32bit_n
jmp 0x40602d
cmp byte [esp + 0xf], 0
je 0x405e50
mov ecx, esi
call fcn.00404f80
test al, al
jne 0x405e50
push dword [esi + 0x10]
push dword [esi + 0xc]
push str._Excluding__s__s_because_it_doesnt_look_32bit_n
call fcn.00401130
add esp, 0xc
mov esi, dword [esi + 4]
test esi, esi
jne 0x405d80
lea ebx, [esi + 0x67]
jmp 0x405e58
push 0x40000
push esi
call fcn.004150a6
add esp, 4
push eax
call fcn.00414eb7
push 0
push 1
mov edx, esi
mov dword [esp + 0x24], eax
mov ecx, edi
call fcn.00405280
push esi
mov edi, eax
call fcn.0040f301
mov eax, dword [esp + 0x28]
add esp, 0x14
test eax, eax
js 0x406093
push eax
push esi
call fcn.004150a6
add esp, 4
push eax
call fcn.00414eb7
add esp, 8
test edi, edi
jne 0x406505
mov edi, ebx
cmp ebx, 0x67
mov ebx, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
jne 0x4060b8
push 0
push 0
push str.PYLAUNCHER_ALLOW_INSTALL
call ebx
cmp eax, 2
jae 0x4060cc
push 0
push 0
push str.PYLAUNCHER_ALWAYS_INSTALL
call ebx
cmp eax, 2
jb 0x4061f2
lea ecx, [esp + 0x20]
call fcn.00404b30
mov edi, eax
test edi, edi
jne 0x4061f2
lea edx, [esp + 0x10]
mov dword [esp + 0x1c], eax
lea ecx, [esp + 0x20]
call fcn.00405a90
mov edi, eax
test edi, edi
jne 0x406505
mov ecx, dword [esp + 0x10]
test ecx, ecx
jne 0x40610a
lea edi, [eax + 0x70]
jmp 0x40640f
mov dword [esp + 0x14], 0
mov esi, ecx
mov edx, dword [esi]
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x24]
call fcn.00404ff0
mov edi, eax
add esp, 4
test edi, edi
je 0x406138
cmp edi, 0x67
jne 0x4061ec
jmp 0x406144
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x4061e6
cmp byte [esi + 0x2c], 0
je 0x406155
cmp byte [esp + 0x55], 0
jne 0x4061e4
cmp byte [esp + 0x54], 0
jne 0x406272
mov edi, dword [esp + 0x44]
test edi, edi
je 0x4061cc
mov ebx, dword [esp + 0x48]
test ebx, ebx
je 0x4061cc
mov eax, dword [esi + 0xc]
mov dword [esp + 0x18], eax
test eax, eax
je 0x4061c1
push 0
push 0
push 0
push ebx
push edi
push 0xffffffffffffffff
push eax
push 9
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x4061c1
sub eax, 1
je 0x40626b
sub eax, 1
je 0x406261
push edi
push ebx
push dword [esp + 0x20]
push 0xffffffffffffffff
push str.Error_comparing__.s_and__.s__compare_
push 0
call fcn.00401200
add esp, 0x18
or eax, 0xffffffff
test eax, eax
jne 0x4063f7
push 0xffffffffffffffff
mov edx, esi
lea ecx, [esp + 0x24]
call fcn.00404e40
add esp, 4
test al, al
je 0x4063f7
mov eax, esi
xor edi, edi
mov dword [esp + 0x1c], eax
mov ebx, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp edi, 0x67
jne 0x40640a
push 2
call fcn.0040ef6d
add esp, 4
push eax
push str.No_suitable_Python_runtime_found_n
call fcn.00414d23
push 2
call fcn.0040ef6d
add esp, 0xc
push eax
push str.Pass___list___0__to_see_all_detected_environments_on_your_machine_n
call fcn.00414d23
add esp, 8
push 0
push 0
push str.PYLAUNCHER_ALLOW_INSTALL
call ebx
cmp eax, 2
jae 0x406505
cmp byte [esp + 0x54], 0
je 0x406505
push 2
call fcn.0040ef6d
add esp, 4
push eax
push str.or_set_environment_variable_PYLAUNCHER_ALLOW_INSTALL_to_use_winget_nor_open_the_Microsoft_Store_to_the_requested_version._n
call fcn.00414d23
jmp 0x406502
mov eax, 1
jmp 0x4061c4
xor eax, eax
jmp 0x4061c4
mov edi, dword [esi + 0xc]
test edi, edi
je 0x4063f7
push 0
push 0
push 0
push 0xffffffffffffffff
push str.PythonCore
push 0xffffffffffffffff
push edi
push 9
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x4063f7
sub eax, 1
je 0x4062cf
sub eax, 1
je 0x4063f7
push str.PythonCore
push 0xffffffffffffffff
push edi
push 0xffffffffffffffff
push str.Error_comparing__.s_and__.s__compare_
push 0
call fcn.00401200
add esp, 0x18
jmp 0x4063f7
mov ebx, dword [esp + 0x50]
mov byte [esp + 0xf], 0
mov byte [esp + 0xe], 0
cmp ebx, 3
jle 0x406398
mov eax, dword [esp + 0x4c]
lea ecx, [ebx - 3]
mov dword [esp + 0x18], ecx
lea edi, [eax + ecx*2]
test edi, edi
je 0x406398
push 0
push 0
push 0
push 3
push 0x42b210
push 3
push edi
push 0
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x406341
sub eax, 1
je 0x406388
sub eax, 1
je 0x406341
push 0x42b210
push 3
push edi
push 3
push str.Error_comparing__.s_and__.s__compareArgument_
push 0
call fcn.00401200
add esp, 0x18
push 0
push 0
push 0
push 3
push 0x429eb0
push 3
push edi
push 0
push 0x428ea8
call dword [sym.imp.KERNEL32.dll_CompareStringEx]
sub eax, 1
je 0x406398
sub eax, 1
je 0x40638f
sub eax, 1
je 0x406398
push 0x429eb0
push 3
push edi
push 3
push str.Error_comparing__.s_and__.s__compareArgument_
push 0
call fcn.00401200
add esp, 0x18
jmp 0x406398
mov byte [esp + 0xf], 1
jmp 0x406394
mov byte [esp + 0xe], 1
mov ebx, dword [esp + 0x18]
push ebx
mov edx, esi
lea ecx, [esp + 0x24]
call fcn.00404e40
add esp, 4
test al, al
je 0x4063f7
cmp byte [esp + 0xf], 0
je 0x4063ca
mov ecx, esi
call fcn.00404f80
test al, al
je 0x4063ca
push dword [esi + 0x10]
push dword [esi + 0xc]
push str._Excluding__s__s_because_it_looks_like_32bit_n
jmp 0x4063ef
cmp byte [esp + 0xe], 0
je 0x4061e4
mov ecx, esi
call fcn.00404f80
test al, al
jne 0x4061e4
push dword [esi + 0x10]
push dword [esi + 0xc]
push str._Excluding__s__s_because_it_doesnt_look_32bit_n
call fcn.00401130
add esp, 0xc
mov esi, dword [esi + 4]
test esi, esi
jne 0x406114
lea edi, [esi + 0x67]
jmp 0x4061ec
cmp edi, 0x70
jne 0x406429
push 2
call fcn.0040ef6d
add esp, 4
push eax
push str.No_installed_Python_found__n
call fcn.00414d23
jmp 0x406502
test edi, edi
jne 0x406505
mov ebx, dword [esp + 0x1c]
test ebx, ebx
je 0x40644e
push dword [ebx + 0x10]
push dword [ebx + 0xc]
push str.env.company:__s_nenv.tag:__s_n
call fcn.00401130
add esp, 0xc
jmp 0x40645b
push str.env.company:__null__nenv.tag:__null__n
call fcn.00401130
add esp, 4
push ecx
lea eax, [esp + 0x6c]
mov edx, ebx
push eax
lea ecx, [esp + 0x28]
call fcn.00405440
mov edi, eax
add esp, 8
test edi, edi
jne 0x406505
lea eax, [esp + 0x68]
push eax
call fcn.00405790
add esp, 4
mov edi, eax
jmp 0x406505
push 1
call fcn.0040ef6d
mov ebx, dword [esp + 0x14]
add esp, 4
mov esi, eax
test ebx, ebx
jne 0x4064ba
push str.No_installed_Pythons_found__n
push 1
call fcn.0040ef6d
add esp, 4
push eax
call fcn.00401050
add esp, 8
xor edi, edi
jmp 0x406509
push 0x40000
push esi
call fcn.004150a6
add esp, 4
push eax
call fcn.00414eb7
push dword [esp + 0x24]
mov ecx, dword [esp + 0x1c]
mov edx, esi
push dword [esp + 0x67]
mov ebx, eax
call fcn.00405280
push esi
mov edi, eax
call fcn.0040f301
add esp, 0x14
test ebx, ebx
js 0x406505
push ebx
push esi
call fcn.004150a6
add esp, 4
push eax
call fcn.00414eb7
add esp, 8
mov ebx, dword [esp + 0x10]
mov eax, dword [esp + 0x64]
test eax, eax
je 0x406522
mov esi, dword [eax]
push eax
call fcn.004152cb
add esp, 4
mov eax, esi
test esi, esi
jne 0x406511
test ebx, ebx
je 0x40658d
push dword [ebx + 0xc]
call fcn.004152cb
add esp, 4
push dword [ebx + 0x10]
call fcn.004152cb
add esp, 4
push dword [ebx + 0x18]
call fcn.004152cb
add esp, 4
push dword [ebx + 0x1c]
call fcn.004152cb
add esp, 4
push dword [ebx + 0x20]
call fcn.004152cb
add esp, 4
push dword [ebx + 0x28]
call fcn.004152cb
mov ecx, dword [ebx]
add esp, 4
call fcn.00403220
mov ecx, dword [ebx + 4]
mov dword [ebx], 0
call fcn.00403220
push ebx
mov dword [ebx + 4], 0
call fcn.004152cb
add esp, 4
mov ecx, dword [esp + 0x1006c]
mov eax, edi
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004065bc
mov esp, ebp
pop ebp
ret