Description
pypdf is a free and open-source pure-python PDF library. Prior to 6.21.3, pypdf can consume excessive memory while opening a crafted PDF containing cross-reference streams that declare very large entry counts. Highly compressible streams and /Prev chains can multiply the number of parsed entries across a document, while negative /Index counts can bypass the existing per-stream clamp. This issue is fixed in version 6.21.3.
Published: 2026-10-29
Score: 7.1 High
EPSS: n/a
KEV: No
Impact: Large memory consumption leading to denial of service
Action: Apply patch
AI Analysis

Impact

The vulnerability causes the pypdf library to allocate excessive amounts of memory when parsing PDF cross‑reference streams that declare very large entry counts. A crafted PDF can include highly compressible streams and a /Prev chain that multiplies the number of parsed entries, and negative /Index values can bypass the existing per‑stream clamp. An attack that leverages this flaw can exhaust an application's memory, making it unresponsive or forcing it to terminate. The weakness is a classic resource exhaustion (CWE‑400) and a failure to appropriately limit data sizes (CWE‑770).

Affected Systems

The flaw affects the py‑pdf distribution of pypdf. Any installation of pypdf earlier than version 6.21.3 is vulnerable. The library is commonly used in Python projects that process PDF files, so any software that imports or depends on pypdf and accepts user supplied PDFs may be impacted.

Risk and Exploitability

The CVSS score of 7.1 indicates a moderate severity risk. The EPSS score is not available, and the vulnerability is not listed in the CISA KEV catalog, suggesting the likelihood of a public exploit is uncertain but still plausible. Attackers would need to supply a specially crafted PDF to the vulnerable application; depending on the context, the file could be uploaded, downloaded, or opened locally. Once delivered, the parser will allocate memory proportional to the declared entry count, potentially blowing the process’s memory limit or exhausting system resources. The exploitability is primarily local or remote, depending on how the application receives PDF inputs, but the impact on availability is substantial if the application is critical.

Generated by OpenCVE AI on October 29, 2026 at 21:27 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to pypdf version 6.21.3 or later, which includes the fix for the excessive memory usage.
  • If upgrading is not immediately possible, validate PDFs from untrusted sources for size and complexity before passing them to pypdf, and reject those that exceed reasonable limits.
  • Configure resource limits for the process that loads PDFs so that excessive memory consumption cannot take down the application, and monitor memory usage for anomalous spikes.

Generated by OpenCVE AI on October 29, 2026 at 21:27 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Thu, 29 Oct 2026 21:45:00 +0000

Type Values Removed Values Added
First Time appeared Py-pdf
Py-pdf pypdf
Vendors & Products Py-pdf
Py-pdf pypdf

Thu, 29 Oct 2026 20:45:00 +0000

Type Values Removed Values Added
Description pypdf is a free and open-source pure-python PDF library. Prior to 6.21.3, pypdf can consume excessive memory while opening a crafted PDF containing cross-reference streams that declare very large entry counts. Highly compressible streams and /Prev chains can multiply the number of parsed entries across a document, while negative /Index counts can bypass the existing per-stream clamp. This issue is fixed in version 6.21.3.
Title pypdf: Possible large memory usage when parsing cross-reference streams
Weaknesses CWE-400
CWE-770
References
Metrics cvssV4_0

{'score': 7.1, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-10-29T20:43:03.072Z

Reserved: 2026-10-29T16:04:48.729Z

Link: CVE-2026-119209

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-29T21:17:20.230

Modified: 2026-10-29T21:17:20.230

Link: CVE-2026-119209

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-29T21:30:15Z

Weaknesses
  • CWE-400

    Uncontrolled Resource Consumption

  • CWE-770

    Allocation of Resources Without Limits or Throttling