Skip to main content

pypdf EUVDEUVD-2026-32912

| CVE-2026-48735 MEDIUM
Allocation of Resources Without Limits or Throttling (CWE-770)
2026-05-28 GitHub_M GHSA-wjqc-6w8f-h24c
6.9
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Craft PDF with oversized or element-dense XMP metadata
  2. Delivery
    Deliver PDF to target application accepting PDF input
  3. Exploit
    Application invokes pypdf to parse PDF
  4. Install
    pypdf XMP parser allocates unbounded memory for XML processing
  5. C2
    System memory exhausted
  6. Execute
    Process crash or OOM kill
  7. Impact
    Denial of service achieved

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A06:2025 - Insecure Design
ASVS 5.0
V2 - Validation and Business Logic Resource allocation limits
MITRE ATT&CK

1 technique across 1 tactic: Impact

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires three concrete conditions: (1) the target application must use a pypdf version prior to 6.12.1; (2) the processed PDF must contain XMP metadata - applications that encounter PDFs without XMP blocks, or that skip XMP parsing, are not affected; and (3) the attacker must be able to supply a PDF file to the vulnerable parsing code path, either directly (local file access) or indirectly (via an upload endpoint, email attachment processor, or similar). No authentication is required from the attacker per CVSS PR:N. Exploitation is limited to availability impact only - no data exfiltration or code execution is possible through this vulnerability. The attack does not require any non-default configuration of pypdf itself, as XMP parsing is standard library behavior triggered by the presence of XMP metadata in a PDF.

Impact

The CVSS 4.0 score of 6.9 reflects local attack vector (AV:L), low complexity (AC:L), no privilege requirement (PR:N), no user interaction (UI:N), and high availability impact (VA:H) with zero confidentiality or integrity impact - a targeted denial-of-service profile. The local attack vector is characteristic of file-based library vulnerabilities: the attacker does not directly reach a network socket but instead supplies a crafted file that a local or server-side process parses. Critically, any server-side PDF processing pipeline that accepts untrusted uploads effectively converts this to a remote DoS from the attacker's perspective, elevating practical risk beyond the raw AV:L designation. No EPSS score was included in the input data, preventing probabilistic exploitation likelihood assessment. KEV status is absent, meaning no confirmed active exploitation has been reported to CISA. The attack is not automatable in the SSVC sense unless paired with an upload endpoint. Overall assessment: moderate priority for document-processing services accepting untrusted PDFs; lower priority for offline tooling or controlled-input environments.

Exploit ScenarioDerived

An attacker crafts a PDF file containing an XMP metadata stream either exceeding 5 MB in raw byte size or embedding over 100,000 XML elements - construction is trivial and directly derivable from the public test cases added in the patch PR at https://github.com/py-pdf/pypdf/pull/3796. The crafted PDF is submitted to a document ingestion service, file conversion tool, or any web application that parses uploaded PDFs using a vulnerable version of pypdf, causing the parsing process to allocate memory proportional to the XMP payload until the system runs out of memory or the process is killed, resulting in service disruption.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 28, 2026

Memory exhaustion in pypdf's XMP metadata parser allows denial of service via specially crafted PDF files containing oversized or element-dense XMP blocks, affecting all versions prior to 6.12.1. The vulnerability stems from an absence of input limits in the XML-based XMP parsing subsystem (CWE-770), meaning processing a malicious PDF can consume unbounded system memory. No public exploit code has been identified at time of analysis, and no confirmed active exploitation exists; however, the patch diff is publicly visible on GitHub, making trivial exploit construction feasible.

RemediationAI

Upgrade pypdf to version 6.12.1 or later, the confirmed vendor-released patch available at https://github.com/py-pdf/pypdf/releases/tag/6.12.1. Version 6.12.1 introduces configurable hard limits of 5 MB on XMP stream size (XMP_MAX_INPUT_LENGTH) and 100,000 on XML element count (XMP_MAX_ELEMENT_COUNT); these constants are exposed as module-level attributes in pypdf.xmp and can be tuned downward if stricter limits are warranted. If an immediate upgrade is blocked, a compensating control is to enforce a file size or metadata size ceiling in the application layer before invoking pypdf - for example, rejecting PDFs whose raw file size exceeds a defined threshold, or stripping XMP metadata using a separate tool prior to parsing. Note that stripping XMP data may affect downstream metadata-dependent workflows. Another option is to wrap pypdf XMP parsing calls in a subprocess with memory limits enforced by the OS (e.g., ulimit -v on Linux), which bounds the blast radius to the subprocess rather than the main application - at the cost of added latency and complexity.

Affected VersionsENISA

pypdf < 6.12.1

Affected Packages

pypi pypdf fix: 6.12.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

pypdf is a widely-used pure-Python PDF library (CPE: cpe:2.3:a:py-pdf:pypdf:*:*:*:*:*:*:*:*) that implements XMP (Extensible Metadata Platform) metadata parsing via a custom XML parser class (_XmpBuilder) derived from Python's ExpatBuilderNS in pypdf/xmp.py. Prior to 6.12.1, this parser imposed no constraints on either the byte length of the XMP data stream or the count of XML elements processed during parsing - a textbook instance of CWE-770 (Allocation of Resources Without Limits or Throttling). An attacker embedding a multi-megabyte XMP block or crafting one with hundreds of thousands of XML elements causes the Python process to allocate memory proportional to the input size with no ceiling. The fix introduces two tunable constants: XMP_MAX_INPUT_LENGTH (defaulting to 5,000,000 bytes) and XMP_MAX_ELEMENT_COUNT (defaulting to 100,000), enforced by raising a LimitReachedError early in parsing. The element limit is enforced via a custom start_element_handler hook on the Expat parser, and the stream length check gates parsing before any XML processing begins.

Know when Pypdf gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 6.9 MEDIUM
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
SUSE 5.5 MEDIUM
AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
Red Hat 5.5 MEDIUM

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

3
Patch available
May 28, 2026 - 17:01 EUVD
CVSS changed
May 28, 2026 - 16:22 NVD
6.9 (MEDIUM)
CVE Published
May 28, 2026 - 14:49 nvd
UNKNOWN (no severity yet)

DescriptionCVE.org

pypdf is a free and open-source pure-python PDF library. Prior to 6.12.1, an attacker who uses this vulnerability can craft a PDF which leads to large memory usage. This requires parsing large XMP metadata, possibly with lots of unnecessary elements. This vulnerability is fixed in 6.12.1.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 1 pypi packages depend on pypdf (1 direct, 0 indirect)

Ecosystem-wide dependent count for version 6.12.1.

Threat Intelligence Overview

EPSS Score
0.0%
Top 98% exploitable
Threat Intel
1
1 source
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation
None
System Exposure· derived
Small
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

34
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +34
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

More in Pypdf

View all
CVE-2026-119209 HIGH POC
7.1 Oct 29

Memory exhaustion while parsing crafted PDFs in pypdf versions prior to 6.21.3 allows an attacker to drive a consuming p

CVE-2026-119208 HIGH POC
7.1 Oct 29

Denial of service in pypdf before 6.21.3: retrieving the page count (for example via len(reader.pages) or get_num_pages(

CVE-2026-119207 HIGH POC
7.1 Oct 29

Memory exhaustion in the pypdf PDF library before 6.21.3 allows a small, deliberately malformed PDF dictionary to blow u

CVE-2026-119206 HIGH POC
7.1 Oct 29

pypdf before 6.21.3 can be driven into excessive CPU consumption when an application retrieves page labels from a specia

CVE-2026-119205 HIGH POC
7.1 Oct 29

Cloning or duplicating a crafted cyclic DictionaryObject with pypdf before 6.21.4 can hang the calling process in an inf

CVE-2026-119204 HIGH POC
7.1 Oct 29

Parsing a crafted PDF with pypdf before 6.21.4 can drive disproportionate memory consumption when the library enumerates

CVE-2026-119203 HIGH POC
7.1 Oct 29

Denial of service in pypdf prior to 6.21.4 lets remote attackers hang a PDF-processing thread by supplying an incomplete

CVE-2026-84309 MEDIUM POC
6.9 Sep 01

Infinite loop denial of service in pypdf prior to 6.16.0 allows any attacker who can supply a crafted PDF to a pypdf-bas

CVE-2026-54651 MEDIUM POC
6.9 Jun 22

Infinite loop denial-of-service in pypdf prior to 6.13.1 allows an attacker to hang any process that merges a crafted PD

CVE-2023-36810 MEDIUM POC
6.5 Jun 30

pypdf is a pure-python PDF library capable of splitting, merging, cropping, and transforming the pages of PDF files. Rat

CVE-2023-36807 MEDIUM POC
6.5 Jun 30

pypdf is a pure-python PDF library capable of splitting, merging, cropping, and transforming the pages of PDF files. Rat

CVE-2023-36464 MEDIUM POC
5.5 Jun 27

pypdf is an open source, pure-python PDF library. Rated medium severity (CVSS 5.5), this vulnerability is no authenticat

Vendor StatusVendor

SUSE

Severity: Medium

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy