Description
Python 3.x through 3.9.1 has a buffer overflow in PyCArg_repr in _ctypes/callproc.c, which may lead to remote code execution in certain Python applications that accept floating-point numbers as untrusted input, as demonstrated by a 1e300 argument to c_double.from_param. This occurs because sprintf is used unsafely.
Published: 2021-01-19
Score: 9.8 Critical
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

No analysis available yet.

Remediation

No remediation available yet.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Debian DLA Debian DLA DLA-2619-1 python3.5 security update
Debian DLA Debian DLA DLA-2919-1 python2.7 security update
Debian DLA Debian DLA DLA-3432-1 python2.7 security update
EUVD EUVD EUVD-2021-26520 Python 3.x through 3.9.1 has a buffer overflow in PyCArg_repr in _ctypes/callproc.c, which may lead to remote code execution in certain Python applications that accept floating-point numbers as untrusted input, as demonstrated by a 1e300 argument to c_double.from_param. This occurs because sprintf is used unsafely.
Ubuntu USN Ubuntu USN USN-4754-1 Python vulnerabilities
Ubuntu USN Ubuntu USN USN-4754-3 Python vulnerabilities
Ubuntu USN Ubuntu USN USN-4754-4 Python 2.7 vulnerability
Ubuntu USN Ubuntu USN USN-4754-5 Python vulnerability
Ubuntu USN Ubuntu USN USN-6891-1 Python vulnerabilities
References
Link Providers
https://bugs.python.org/issue42938 cve-icon cve-icon
https://github.com/python/cpython/pull/24239 cve-icon cve-icon
https://lists.apache.org/thread.html/rf9fa47ab66495c78bb4120b0754dd9531ca2ff0430f6685ac9b07772%40%3Cdev.mina.apache.org%3E cve-icon cve-icon
https://lists.debian.org/debian-lts-announce/2021/04/msg00005.html cve-icon cve-icon
https://lists.debian.org/debian-lts-announce/2022/02/msg00013.html cve-icon cve-icon
https://lists.debian.org/debian-lts-announce/2023/05/msg00024.html cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/BRHOCQYX3QLDGDQGTWQAUUT2GGIZCZUO/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/CCFZMVRQUKCBQIG5F2CBVADK63NFSE4A/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FONHJIOZOFD7CD35KZL6SVBUTMBPGZGA/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FPE7SMXYUIWPOIZV4DQYXODRXMFX3C5E/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/HCQTCSP6SCVIYNIRUJC5X7YBVUHPLSC4/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MGSV6BJQLRQ6RKVUXK7JGU7TP4QFGQXC/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MP572OLHMS7MZO4KUPSCIMSZIA5IZZ62/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NODWHDIFBQE5RU5PUWUVE47JOT5VCMJ2/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NQPARTLNSFQVMMQHPNBFOCOZOO3TMQNA/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NXSMBHES3ANXXS2RSO5G6Q24BR4B2PWK/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/V6XJAULOS5JVB2L67NCKKMJ5NTKZJBSD/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Y4KSYYWMGAKOA2JVCQA422OINT6CKQ7O/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/YDTZVGSXQ7HR7OCGSUHTRNTMBG43OMKU/ cve-icon cve-icon
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Z7GZV74KM72O2PEJN2C4XP3V5Q5MZUOO/ cve-icon cve-icon
https://news.ycombinator.com/item?id=26185005 cve-icon cve-icon
https://nvd.nist.gov/vuln/detail/CVE-2021-3177 cve-icon
https://python-security.readthedocs.io/vuln/ctypes-buffer-overflow-pycarg_repr.html cve-icon cve-icon
https://security.gentoo.org/glsa/202101-18 cve-icon cve-icon
https://security.netapp.com/advisory/ntap-20210226-0003/ cve-icon cve-icon
https://www.cve.org/CVERecord?id=CVE-2021-3177 cve-icon
https://www.oracle.com//security-alerts/cpujul2021.html cve-icon cve-icon
https://www.oracle.com/security-alerts/cpujan2022.html cve-icon cve-icon
https://www.oracle.com/security-alerts/cpujul2022.html cve-icon cve-icon
https://www.oracle.com/security-alerts/cpuoct2021.html cve-icon cve-icon
History

Thu, 18 Dec 2025 16:15:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Subscriptions

Debian Debian Linux
Fedoraproject Fedora
Netapp Active Iq Unified Manager Ontap Select Deploy Administration Utility
Oracle Communications Cloud Native Core Network Function Cloud Native Environment Communications Offline Mediation Controller Communications Pricing Design Center Enterprise Manager Ops Center Zfs Storage Appliance Kit
Python Python
Redhat Enterprise Linux Rhel Software Collections
cve-icon MITRE

Status: PUBLISHED

Assigner: mitre

Published:

Updated: 2025-12-18T15:03:34.545Z

Reserved: 2021-01-19T00:00:00.000Z

Link: CVE-2021-3177

cve-icon Vulnrichment

Updated: 2024-08-03T16:45:51.394Z

cve-icon NVD

Status : Modified

Published: 2021-01-19T06:15:12.967

Modified: 2025-12-18T15:15:48.873

Link: CVE-2021-3177

cve-icon Redhat

Severity : Moderate

Publid Date: 2021-01-19T00:00:00Z

Links: CVE-2021-3177 - Bugzilla

cve-icon OpenCVE Enrichment

No data.

Weaknesses