CVE-2023-46250
Description
pypdf is a free and open-source pure-python PDF library. An attacker who uses a vulnerability present in versions 3.7.0 through 3.16.4 can craft a PDF which leads to an infinite loop. This infinite loop blocks the current process and can utilize a single core of the CPU by 100%. It does not affect memory usage. That is, for example, the case when the pypdf-user manipulates an incoming malicious PDF e.g. by merging it with another PDF or by adding annotations. The issue was fixed in version 3.17.0. As a workaround, apply the patch manually by modifying `pypdf/generic/_data_structures.py`.
Weakness
- CWE-835: Loop with Unreachable Exit Condition
CISA SSVC decision points
| Exploitation | none |
|---|---|
| Automatable | no |
| Technical impact | partial |
| Scored | 2024-09-05 |
Timeline
- 2023-10-31Published by the CNA15:23 UTC
- 2023-10-31GitHub advisory published (GHSA-wjcc-cq79-p63f)same day
- 2024-09-05CISA SSVC decision recorded310 days after publication
Exploit and advisory records
GitHub advisory GHSA-wjcc-cq79-p63f, affected packages:
| Package | Vulnerable versions | Fixed in |
|---|---|---|
| PyPI pypdf | from 3.7.0 before 3.17.0 | 3.17.0 |
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| py-pdf pypdf | from 3.7.0 before 3.17.0fixed in 3.17.0 | 3.17.0 |
References
- https://github.com/py-pdf/pypdf/commit/9b23ac3c9619492570011d551d521690de9a3e2d
- https://github.com/py-pdf/pypdf/pull/2264
- https://github.com/py-pdf/pypdf/security/advisories/GHSA-wjcc-cq79-p63f
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2023-46250'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2023-46250'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2023-46250'curl 'https://api.contrastcyber.com/cve_products/CVE-2023-46250'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).