CVE-2021-3177
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
02 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
03 Exploitation and scoring
- Exploitation
- Public exploit code exists. CISA's assessment records a public proof of concept. That is not a report of exploitation in the wild.
- SSVC decision
- ExploitationpocPublic proof-of-concept exploit code exists. Not a report of exploitation in the wild.
- AutomatableyesAn attacker can reliably automate reconnaissance through exploitation, so this scales.
- Technical ImpacttotalSuccessful exploitation gives total control of the vulnerable component.
- EPSS probability
- 24.21% probability of exploitation activity in the next 30 days.
- EPSS percentile
- Equal to or higher than the score of 97.8% of scored records. A rank, not a probability.
- NVD base score
- 9.8 (CVSS v3.x), scored by the NVD independently of the CNA.
- NVD CVSS vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- NVD analysis status
- Modified. NVD last modified this record on 2026-10-14.
- Red Hat severity
- Moderate. Red Hat's rating for its own products, not a CVSS rating.
Exploit-prediction scores from FIRST. Independent scoring and analysis status from the NVD. Vendor severity from Red Hat. Exploitation assessment and catalog membership from CISA.
04 Metadata
- Published
- 2021-01-19 00:00Z5 YR AGO
- Last updated
- 2026-10-14 09:45Z15 DAYS AGO
- Reserved
- 2021-01-19
- Assigning CNA
- mitre
- Record state
- PUBLISHED
- Severity
- Critical (CVSS 9.8)
- CNA CVSS vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Weaknesses
- CWE-120Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')Base
- Data version
- 5.2
- Document digest
- 297cdfa24e20b0cc6ade79b4e0b23f485269e77ba5782eb7f7a7396cc1173691
05 Affected products
06 References
- bugs.python.orghttps://bugs.python.org/issue42938
- github.comhttps://github.com/python/cpython/pull/24239
- python-security.readthedocs.iohttps://python-security.readthedocs.io/vuln/ctypes-buffer-overflow-pycarg_repr.html
- lists.fedoraproject.orgFEDORA-2021-faf88b9499https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MGSV6BJQLRQ6RKVUXK7JGU7TP4QFGQXC/
- lists.fedoraproject.orgFEDORA-2021-cc3ff94cfchttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NQPARTLNSFQVMMQHPNBFOCOZOO3TMQNA/
- security.gentoo.orgGLSA-202101-18https://security.gentoo.org/glsa/202101-18
- lists.fedoraproject.orgFEDORA-2021-e3a5a74610https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Z7GZV74KM72O2PEJN2C4XP3V5Q5MZUOO/
- lists.fedoraproject.orgFEDORA-2021-ced31f3f0chttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/CCFZMVRQUKCBQIG5F2CBVADK63NFSE4A/
- lists.fedoraproject.orgFEDORA-2021-42ba9feb47https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/BRHOCQYX3QLDGDQGTWQAUUT2GGIZCZUO/
- lists.fedoraproject.orgFEDORA-2021-076a2dccbahttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NXSMBHES3ANXXS2RSO5G6Q24BR4B2PWK/
- lists.fedoraproject.orgFEDORA-2021-851c6e4e2dhttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/V6XJAULOS5JVB2L67NCKKMJ5NTKZJBSD/
- lists.fedoraproject.orgFEDORA-2021-66547ff92dhttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/YDTZVGSXQ7HR7OCGSUHTRNTMBG43OMKU/
- lists.fedoraproject.orgFEDORA-2021-17668e344ahttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Y4KSYYWMGAKOA2JVCQA422OINT6CKQ7O/
- lists.fedoraproject.orgFEDORA-2021-d5cde50865https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FPE7SMXYUIWPOIZV4DQYXODRXMFX3C5E/
- lists.fedoraproject.orgFEDORA-2021-7547ad987fhttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/HCQTCSP6SCVIYNIRUJC5X7YBVUHPLSC4/
- lists.fedoraproject.orgFEDORA-2021-f4fd9372c7https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/NODWHDIFBQE5RU5PUWUVE47JOT5VCMJ2/
- lists.fedoraproject.orgFEDORA-2021-3352c1c802https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MP572OLHMS7MZO4KUPSCIMSZIA5IZZ62/
- lists.apache.org[mina-dev] 20210225 [jira] [Created] (FTPSERVER-500) Security vulnerability in common/lib/log4j-1.2.17.jarhttps://lists.apache.org/thread.html/rf9fa47ab66495c78bb4120b0754dd9531ca2ff0430f6685ac9b07772%40%3Cdev.mina.apache.org%3E
- lists.fedoraproject.orgFEDORA-2021-907f3bacaehttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FONHJIOZOFD7CD35KZL6SVBUTMBPGZGA/
- lists.debian.org[debian-lts-announce] 20210405 [SECURITY] [DLA 2619-1] python3.5 security updatehttps://lists.debian.org/debian-lts-announce/2021/04/msg00005.html
- www.oracle.comhttps://www.oracle.com//security-alerts/cpujul2021.html
- news.ycombinator.comhttps://news.ycombinator.com/item?id=26185005
- security.netapp.comhttps://security.netapp.com/advisory/ntap-20210226-0003/
- www.oracle.comhttps://www.oracle.com/security-alerts/cpuoct2021.html
- www.oracle.comhttps://www.oracle.com/security-alerts/cpujan2022.html
- lists.debian.org[debian-lts-announce] 20220212 [SECURITY] [DLA 2919-1] python2.7 security updatehttps://lists.debian.org/debian-lts-announce/2022/02/msg00013.html
- www.oracle.comhttps://www.oracle.com/security-alerts/cpujul2022.html
- lists.debian.org[debian-lts-announce] 20230524 [SECURITY] [DLA 3432-1] python2.7 security updatehttps://lists.debian.org/debian-lts-announce/2023/05/msg00024.html
- cert-portal.siemens.comhttps://cert-portal.siemens.com/productcert/html/ssa-398330.html
07 Fixed in
AlmaLinux 8
- python-psycopg2-doc Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python-sqlalchemy-doc Fixed
A version is affected if any line below covers it.
- Affected before 1.3.2-2.module_el8.5.0+2569+5c5719bc
- Affected before 1.3.2-2.module_el8.6.0+2781+fed64c13
- python2-Cython Fixed in 0.28.1-7.module_el8.6.0+2781+fed64c13
- python2-PyMySQL Fixed in 0.8.0-10.module_el8.6.0+2781+fed64c13
- python2-attrs Fixed in 17.4.0-10.module_el8.6.0+2781+fed64c13
- python2-backports Fixed in 1.0-16.module_el8.6.0+2781+fed64c13
- python2-backports-ssl_match_hostname Fixed in 3.5.0.1-12.module_el8.6.0+2781+fed64c13
- python2-chardet Fixed in 3.0.4-10.module_el8.6.0+2781+fed64c13
- python2-coverage Fixed in 4.5.1-4.module_el8.6.0+2781+fed64c13
- python2-dns Fixed in 1.15.0-10.module_el8.6.0+2781+fed64c13
- python2-docs Fixed in 2.7.16-2.module_el8.6.0+2781+fed64c13
- python2-docs-info Fixed in 2.7.16-2.module_el8.6.0+2781+fed64c13
- python2-docutils Fixed in 0.14-12.module_el8.6.0+2781+fed64c13
- python2-funcsigs Fixed in 1.0.2-13.module_el8.6.0+2781+fed64c13
- python2-idna Fixed in 2.5-7.module_el8.6.0+2781+fed64c13
- python2-ipaddress Fixed in 1.0.18-6.module_el8.6.0+2781+fed64c13
- python2-markupsafe Fixed in 0.23-19.module_el8.6.0+2781+fed64c13
- python2-mock Fixed in 2.0.0-13.module_el8.6.0+2781+fed64c13
- python2-numpy Fixed in 1:1.14.2-16.module_el8.6.0+2781+fed64c13
- python2-numpy-doc Fixed in 1:1.14.2-16.module_el8.6.0+2781+fed64c13
- python2-numpy-f2py Fixed in 1:1.14.2-16.module_el8.6.0+2781+fed64c13
- python2-pluggy Fixed in 0.6.0-8.module_el8.6.0+2781+fed64c13
- python2-psycopg2 Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python2-psycopg2-debug Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python2-psycopg2-tests Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python2-py Fixed in 1.5.3-6.module_el8.6.0+2781+fed64c13
- python2-pysocks Fixed in 1.6.8-6.module_el8.6.0+2781+fed64c13
- python2-pytest Fixed in 3.4.2-13.module_el8.6.0+2781+fed64c13
- python2-pytest-mock Fixed in 1.9.0-4.module_el8.6.0+2781+fed64c13
- python2-pytz Fixed in 2017.2-12.module_el8.6.0+2781+fed64c13
- python2-pyyaml Fixed in 3.12-16.module_el8.6.0+2781+fed64c13
- python2-requests Fixed in 2.20.0-3.module_el8.6.0+2781+fed64c13
- python2-rpm-macros Fixed in 3-38.module_el8.6.0+2781+fed64c13
- python2-setuptools Fixed in 39.0.1-13.module_el8.6.0+2781+fed64c13
- python2-setuptools-wheel Fixed in 39.0.1-13.module_el8.6.0+2781+fed64c13
- python2-setuptools_scm Fixed in 1.15.7-6.module_el8.6.0+2781+fed64c13
- python2-six Fixed in 1.11.0-6.module_el8.6.0+2781+fed64c13
- python2-sqlalchemy Fixed in 1.3.2-2.module_el8.6.0+2781+fed64c13
- python2-urllib3 Fixed in 1.24.2-3.module_el8.6.0+2781+fed64c13
- python38-Cython Fixed in 0.29.14-4.module_el8.6.0+2778+cd494b30
18 further packages in AlmaLinux 8 not shown (first 40 listed).
Source: AlmaLinux, AlmaLinux OS. Copyright (c) 2023 AlmaLinux OS. Licensed under MIT License. Received through OSV.dev. Reformatted by exploit.cc.
Arch Linux
- python Fixed in 3.9.2-1
Source: Arch Linux Security Tracker, the Arch Linux security team. Reformatted by exploit.cc.
CloudLinux 8
- python-psycopg2-doc Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python-sqlalchemy-doc Fixed
A version is affected if any line below covers it.
- Affected before 1.3.2-2.module_el8.5.0+2569+5c5719bc
- Affected before 1.3.2-2.module_el8.6.0+2781+fed64c13
- python2-Cython Fixed in 0.28.1-7.module_el8.6.0+2781+fed64c13
- python2-PyMySQL Fixed in 0.8.0-10.module_el8.6.0+2781+fed64c13
- python2-attrs Fixed in 17.4.0-10.module_el8.6.0+2781+fed64c13
- python2-backports Fixed in 1.0-16.module_el8.6.0+2781+fed64c13
- python2-backports-ssl_match_hostname Fixed in 3.5.0.1-12.module_el8.6.0+2781+fed64c13
- python2-chardet Fixed in 3.0.4-10.module_el8.6.0+2781+fed64c13
- python2-coverage Fixed in 4.5.1-4.module_el8.6.0+2781+fed64c13
- python2-dns Fixed in 1.15.0-10.module_el8.6.0+2781+fed64c13
- python2-docs Fixed in 2.7.16-2.module_el8.6.0+2781+fed64c13
- python2-docs-info Fixed in 2.7.16-2.module_el8.6.0+2781+fed64c13
- python2-docutils Fixed in 0.14-12.module_el8.6.0+2781+fed64c13
- python2-funcsigs Fixed in 1.0.2-13.module_el8.6.0+2781+fed64c13
- python2-idna Fixed in 2.5-7.module_el8.6.0+2781+fed64c13
- python2-ipaddress Fixed in 1.0.18-6.module_el8.6.0+2781+fed64c13
- python2-markupsafe Fixed in 0.23-19.module_el8.6.0+2781+fed64c13
- python2-mock Fixed in 2.0.0-13.module_el8.6.0+2781+fed64c13
- python2-numpy Fixed in 1:1.14.2-16.module_el8.6.0+2781+fed64c13
- python2-numpy-doc Fixed in 1:1.14.2-16.module_el8.6.0+2781+fed64c13
- python2-numpy-f2py Fixed in 1:1.14.2-16.module_el8.6.0+2781+fed64c13
- python2-pluggy Fixed in 0.6.0-8.module_el8.6.0+2781+fed64c13
- python2-psycopg2 Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python2-psycopg2-debug Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python2-psycopg2-tests Fixed in 2.7.5-7.module_el8.6.0+2781+fed64c13
- python2-py Fixed in 1.5.3-6.module_el8.6.0+2781+fed64c13
- python2-pysocks Fixed in 1.6.8-6.module_el8.6.0+2781+fed64c13
- python2-pytest Fixed in 3.4.2-13.module_el8.6.0+2781+fed64c13
- python2-pytest-mock Fixed in 1.9.0-4.module_el8.6.0+2781+fed64c13
- python2-pytz Fixed in 2017.2-12.module_el8.6.0+2781+fed64c13
- python2-pyyaml Fixed in 3.12-16.module_el8.6.0+2781+fed64c13
- python2-requests Fixed in 2.20.0-3.module_el8.6.0+2781+fed64c13
- python2-rpm-macros Fixed in 3-38.module_el8.6.0+2781+fed64c13
- python2-setuptools Fixed in 39.0.1-13.module_el8.6.0+2781+fed64c13
- python2-setuptools-wheel Fixed in 39.0.1-13.module_el8.6.0+2781+fed64c13
- python2-setuptools_scm Fixed in 1.15.7-6.module_el8.6.0+2781+fed64c13
- python2-six Fixed in 1.11.0-6.module_el8.6.0+2781+fed64c13
- python2-sqlalchemy Fixed in 1.3.2-2.module_el8.6.0+2781+fed64c13
- python2-urllib3 Fixed in 1.24.2-3.module_el8.6.0+2781+fed64c13
- python38-Cython Fixed in 0.29.14-4.module_el8.6.0+2778+cd494b30
18 further packages in CloudLinux 8 not shown (first 40 listed).
Derived from AlmaLinux 8. Partial coverage: only packages taken from AlmaLinux 8 are listed.
Source: CloudLinux errata, CloudLinux Inc. Derived from: AlmaLinux, AlmaLinux OS. Copyright (c) 2023 AlmaLinux OS. Licensed under MIT License. Received through OSV.dev. Reformatted by exploit.cc.
Debian 11
- python2.7 Fixed in 2.7.18-2
- python3.9 Fixed in 3.9.1-3
Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu 16.04 LTS
- python2.7 Fixed in 2.7.12-1ubuntu0~16.04.18
- python3.5 Fixed in 3.5.2-2ubuntu0~16.04.13
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu 18.04 LTS
- python2.7 Fixed in 2.7.17-1~18.04ubuntu1.6
- python3.6 Fixed in 3.6.9-1~18.04ubuntu1.4
- python3.7 Fixed in 3.7.5-2~18.04.4
- python3.8 Fixed in 3.8.0-3~18.04.1
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu 20.04 LTS
- python2.7 Fixed in 2.7.18-1~20.04.1
- python3.8 Fixed in 3.8.5-1~20.04.2
- python3.9 Fixed in 3.9.5-3~20.04.1
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu Pro 14.04 LTS
- python2.7 Fixed in 2.7.6-8ubuntu0.6+esm10Available with Ubuntu Pro (Infra-only): https://ubuntu.com/pro
- python3.4 Fixed in 3.4.3-1ubuntu1~14.04.7+esm10Available with Ubuntu Pro (Infra-only): https://ubuntu.com/pro
- python3.5 Fixed in 3.5.2-2ubuntu0~16.04.4~14.04.1+esm1Available with Ubuntu Pro (Infra-only): https://ubuntu.com/pro
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
A release or ecosystem missing from this list has no record here. It may be unaffected or not covered by the source. Source notices and licences.