Vulnerability · Published Sep 10, 2021 · Assigned by mitre
CVE-2021-40839
High 7.5
In plain English
A high-severity security flaw in the py3-rencode package (Alpine). There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 5.5% (higher than 93% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.
Severity (CVSS NVD)7.5High
Exploit odds (30 days)5.5%top 7.2% of all CVEs
Exploited in the wildNo reportsnot in CISA KEV
Attack tooling1Public PoC
Official description
The rencode package through 1.0.6 for Python allows an infinite loop in typecode decoding (such as via ;\x2f\x7f), enabling a remote attack that consumes CPU and memory.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine:v3.20 | py3-rencode | 1.0.6-r7 | ALPINE-CVE-2021-40839 |
| Alpine:v3.21 | py3-rencode | 1.0.6-r7 | ALPINE-CVE-2021-40839 |
| Alpine:v3.22 | py3-rencode | 1.0.6-r7 | ALPINE-CVE-2021-40839 |
| Alpine:v3.23 | py3-rencode | 1.0.6-r7 | ALPINE-CVE-2021-40839 |
| Alpine:v3.24 | py3-rencode | 1.0.6-r7 | ALPINE-CVE-2021-40839 |
| Debian:12 | python-rencode | 1.0.6-2 | DEBIAN-CVE-2021-40839 |
| Debian:13 | python-rencode | 1.0.6-2 | DEBIAN-CVE-2021-40839 |
| Debian:14 | python-rencode | 1.0.6-2 | DEBIAN-CVE-2021-40839 |
| PyPI | rencode | no fix listed | GHSA-gh8j-2pgf-x458 |
| PyPI | rencode | no fix listed | PYSEC-2021-345 |
| Ubuntu:22.04:LTS | python-rencode | no fix listed | UBUNTU-CVE-2021-40839 |
Affected products (as reported)
References
- https://github.com/aresch/rencode/pull/29 x_refsource_MISC
- https://seclists.org/fulldisclosure/2021/Sep/16 x_refsource_MISC
- https://github.com/aresch/rencode/commit/572ff74586d9b1daab904c6f7f7009ce0143bb75 x_refsource_MISC
- https://pypi.org/project/rencode/#history x_refsource_MISC
- https://security.netapp.com/advisory/ntap-20211008-0001/ x_refsource_CONFIRM
- FEDORA-2022-02340931ec vendor-advisory, x_refsource_FEDORA
- FEDORA-2022-1033a2718b vendor-advisory, x_refsource_FEDORA