Severity by source
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
PDF delivered over network with no auth required; automated library processing requires no user interaction; impact is availability-only resource exhaustion with no C or I effect.
AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Primary rating from Vendor (https://github.com/py-pdf/pypdf).
CVSS VectorVendor: https://github.com/py-pdf/pypdf
Lifecycle Timeline
3Blast Radius
ecosystem impact- 45 pypi packages depend on pypdf (9 direct, 36 indirect)
Ecosystem-wide dependent count for version 6.15.0.
DescriptionCVE.org
Impact
An attacker who uses this vulnerability can craft a PDF which leads to long runtimes and large memory consumption. This requires parsing the font width entries of a font with unusually large values, for example during text extraction.
Patches
This has been fixed in pypdf==6.15.0.
Workarounds
If you cannot upgrade yet, consider applying the changes from PR #3946.
AnalysisAI
Resource exhaustion in pypdf before 6.15.0 enables denial of service via crafted PDF files containing CID font width entries with maliciously large range values. Any application that processes untrusted PDFs using pypdf's text extraction or font parsing routines is affected, as the library iterates over attacker-controlled CID width ranges without bounds enforcement, consuming excessive CPU and memory. No public exploit code has been identified at time of analysis, and this vulnerability is not listed in the CISA KEV catalog.
Technical ContextAI
pypdf (pkg:pip/pypdf) is a pure-Python library for reading, writing, and manipulating PDF files. The vulnerability resides in pypdf/_font.py within the _collect_cid_character_widths function, which processes the /W (Widths) array of CID (Character Identifier) fonts embedded in PDF documents. CID fonts describe character advance widths using two encoding formats: a range format (start_cid, end_cid, single_width) and a list format (start_cid, [width1, width2, ...]). Prior to the fix, no upper bounds were enforced on range sizes or total entry counts, meaning an attacker could encode a /W array with a range spanning billions of CID values. CWE-834 (Excessive Iteration) precisely describes the root cause: the parser faithfully iterates over the attacker-supplied range, attempting to allocate and populate a massive dictionary of character widths until memory or CPU is exhausted. The fix in PR #3946 introduces two hard limits: MAX_CID_WIDTH_ENTRY_COUNT = 65,536 per individual range and MAX_WIDTH_ENTRY_COUNT = 100,000 cumulative entries, raising LimitReachedError when either threshold is exceeded.
RemediationAI
Upgrade pypdf to version 6.15.0 or later, which introduces enforced limits on CID font width entries and raises LimitReachedError for inputs that exceed them (https://github.com/py-pdf/pypdf/releases/tag/6.15.0). If an immediate upgrade is not possible, the fix can be applied manually by backporting the changes from PR #3946 (https://github.com/py-pdf/pypdf/pull/3946) or commit 51cb6acf9e8a35b77e90b4d87d28fe3e1416d7d7, which adds the MAX_CID_WIDTH_ENTRY_COUNT and MAX_WIDTH_ENTRY_COUNT guards to pypdf/_font.py. As a compensating control for services that cannot upgrade, enforce OS-level resource constraints on PDF-processing workers using cgroups or ulimit (e.g., memory cap, CPU time limit) - note this mitigates impact by causing process termination rather than fixing the root cause, and will degrade availability for legitimate large PDFs as well. Additionally, restricting PDF uploads by file size or source IP reduces the attack surface without eliminating the vulnerability.
Same weakness CWE-834 – Excessive Iteration
View allSame technique Information Disclosure
View allVendor StatusVendor
SUSE
Severity: ModerateShare
External POC / Exploit Code
Leaving vuln.today
EUVD-2026-54600
GHSA-fwg2-594c-jp42