CVE-2021-3177
Reported by mitre · Published January 19, 2021
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.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| python-test | Amazon Linux | 2.7.18-1.amzn2.0.3 |
| python3-tools | Amazon Linux | 3.7.9-1.amzn2.0.2 |
| libpython | Bitnami | 3.9.2, 3.8.8, 3.7.10, 3.6.13 |
| python3 | Alpine | 3.8.7-r2, 3.8.7-r1, 3.8.5-r1, 3.8.2-r2, 3.7.7-r2 |
| python | Arch Linux | 3.9.2-1 |
| python-tools | Amazon Linux | 2.7.18-1.amzn2.0.3 |
| python-debug | Amazon Linux | 2.7.18-1.amzn2.0.3 |
| python3-debug | Amazon Linux | 3.7.9-1.amzn2.0.2 |
| python2 | Alpine | 2.7.18-r1 |
| python-libs | Amazon Linux | 2.7.18-1.amzn2.0.3 |
| python3-tkinter | Amazon Linux | 3.7.9-1.amzn2.0.2 |
| python3-libs | Amazon Linux | 3.7.9-1.amzn2.0.2 |
32 more packages have a fixed version. See every fix in Lookup.
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| n/a | n/a | n/a |
| amazon:2 | python-test | 0 |
| amazon:2 | python3-tools | 0 |
| alpine | python3 | 0, 0, 0 |
| arch | python | 0 |
| amazon:2 | python-tools | 0 |
| amazon:2 | python-debug | 0 |
| amazon:2 | python3-debug | 0 |
| alpine | python2 | 0 |
| amazon:2 | python-libs | 0 |
| Siemens | SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP | 3.1.0 |
| Siemens | SIPLUS S7-1500 CPU 1518-4 PN/DP MFP | 3.1.0 |
| amazon:2 | python3-tkinter | 0 |
| amazon:2 | python3-libs | 0 |
| amazon:2 | python-devel | 0 |
| amazon:2 | python3-test | 0 |
| amazon:2 | tkinter | 0 |
| Siemens | SIMATIC S7-1500 CPU 1518-4 PN/DP MFP | 3.1.0 |
| amazon:2 | python3 | 0 |
| amazon:2 | python | 0 |
…and 2 more
Timeline
- Jan 19, 2021 CVE Published
- Apr 14, 2021 EPSS Score (30 in total, the first dated here)
- Aug 25, 2021 PoC Published (3 in total, the first dated here)
- Mar 7, 2026 Distribution Patch (17 in total, the first dated here)
- Mar 7, 2026 Security Advisory (22 in total, the first dated here)
- Aug 1, 2026 Coalition ESS Score
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2021-3177
vulnetix vdb fixes CVE-2021-3177
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2021-3177/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- FEDORA-2021-faf88b9499 vendor-advisory
- FEDORA-2021-cc3ff94cfc vendor-advisory
- GLSA-202101-18 vendor-advisory
- FEDORA-2021-e3a5a74610 vendor-advisory
- FEDORA-2021-ced31f3f0c vendor-advisory
- FEDORA-2021-42ba9feb47 vendor-advisory
- FEDORA-2021-076a2dccba vendor-advisory
- FEDORA-2021-851c6e4e2d vendor-advisory
- FEDORA-2021-66547ff92d vendor-advisory
- FEDORA-2021-17668e344a vendor-advisory
- FEDORA-2021-d5cde50865 vendor-advisory
- FEDORA-2021-7547ad987f vendor-advisory
- FEDORA-2021-f4fd9372c7 vendor-advisory
- FEDORA-2021-3352c1c802 vendor-advisory
- [mina-dev] 20210225 [jira] [Created] (FTPSERVER-500) Security vulnerability in common/lib/log4j-1.2.17.jar mailing-list
- FEDORA-2021-907f3bacae vendor-advisory
- [debian-lts-announce] 20210405 [SECURITY] [DLA 2619-1] python3.5 security update mailing-list
…and 9 more