Vulnerabilities · 2015 · Python
CVE-2015-20107
Python vulnerability
In Python (aka CPython) up to 3.10.8, the mailcap module does not add escape characters into commands discovered in the system mailcap file. This may allow attackers to inject shell commands into applications that call mailcap.findmatch with untrusted input (if they lack validation of user-provided filenames or arguments). The fix is also back-ported to 3.7, 3.8, 3.9
Affected products
Python, Active Iq Unified Manager, Ontap Select Deploy Administration Utility, Snapcenter, Fedora. The exact versions are in the references.
What to do now
- Check your exposureFind out whether Python runs anywhere in your environment, including systems of suppliers.
- UpdateInstall the version in which the vendor fixed the vulnerability. The references lead to the advisory.
- Set the orderSystems that can be reached from the internet come first, then the rest.
References
- bugs.python.org/issue24778 · Exploit
- python-security.readthedocs.io/vuln/mailcap-shell-injection.html · Patch
- github.com/python/cpython/issues/68966 · Third Party Advisory
- security.netapp.com/advisory/ntap-20220616-0001/ · Third Party Advisory
- lists.debian.org/debian-lts-announce/2023/05/msg00024.html
- lists.debian.org/debian-lts-announce/2023/06/msg00039.html
- lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/4
- lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/5
- nvd.nist.gov/vuln/detail/CVE-2015-20107
- cve.org/CVERecord?id=CVE-2015-20107
More vulnerabilities in Python products
CVE-2026-21441CVE-2025-66471CVE-2025-66418CVE-2025-50182CVE-2025-50181CVE-2025-48379CVE-2025-47273CVE-2025-13837All 231
Data: CVE list and the NVD. This product uses data from the NVD API but is not endorsed or certified by the NVD.