PSF-2020-4: High severity Python Software Foundation CPython vulnerability
In Python 3.6 through 3.6.10, 3.7 through 3.7.8, 3.8 through 3.8.4rc1, and 3.9 through 3.9.0b4 on Windows, a Trojan horse python3.dll might be used in cases where CPython is embedded in a native application. This occurs because python3X.dll may use an invalid search path for python3.dll loading (after PySetPath has been used). NOTE: this issue CANNOT occur when using python.exe from a standard (non-embedded) Python installation on Windows.
Affected Software
Event History
Frequently Asked Questions
Which deployments are exposed to this issue?
The issue affects CPython embedded in a native application on Windows, in the listed Python release ranges. Standard use of python.exe from a non-embedded Python installation on Windows cannot be affected.
What would an attacker need to exploit it?
An attacker would need to cause a Trojan horse python3.dll to be used by the embedded application after Py_SetPath has been used. The vulnerable behavior involves an invalid search path when python3X.dll loads python3.dll.