[python-win32] Python installer for Windows not working on silent installation

Romulus G | Heimdal™ rgu at heimdalsecurity.com
Mon Feb 8 14:29:08 EST 2021


Hi Guys,

I am trying to deploy Python (the latest version) through AD GPO or through SCCM.

Since there’s no MSI Installer available on the python.org for the latest versions, I used the python-3.9.1-amd64.exe with the following command line:
python-3.9.0.exe /quiet InstallAllUsers=1 PrependPath=1 Include_test=0

The issue is that the installer runs through the SYSTEM account and it appears that it does not install correctly.

The files are placed in C:\Program Files\Python39 but for some reason, the Python InstallAllUsers=1 call does not register its key in the HKEY_LOCAL_MACHINE\Software path.
The result of this means, from my understanding/testing, that the installer detects that it's not running as an elevated process, and therefore it installs as user NTAUTH\SYSTEM, for NTAUTH\SYSTEM, placing the keys for Python Launcher and the rest in HKCU instead of HKLM.
This explains why installations would fail, uninstallation was impossible no matter what, and why our Python Launcher was behaving weirdly despite PATH being set correctly.
·         Installations would fail because the keys would all still be placed in the HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall\
·         The installers never appeared in Control Panel – Programs and Features despite successful installation, because it was installed for the NTAUTH\SYSTEM and not All Users
Is there something that I am doing wrong or is this a bug?
Thanks.

CONFIDENTIALITY NOTICE: The contents of this email message and any attachments are intended solely for the addressee(s) and may contain confidential and/or privileged information and may be legally protected from disclosure. If you are not the intended recipient of this message or their agent, or if this message has been addressed to you in error, please immediately alert the sender by reply email and then delete this message and any attachments. If you are not the intended recipient, you are hereby notified that any use, dissemination, copying, or storage of this message or its attachments is strictly prohibited.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.python.org/pipermail/python-win32/attachments/20210208/fcf8c3e6/attachment.html>


More information about the python-win32 mailing list