Description
pypdf is a free and open-source pure-python PDF library. Prior to 6.7.1, an attacker who uses this vulnerability can craft a PDF which leads to an infinite loop. This requires accessing the children of a TreeObject, for example as part of outlines. This vulnerability is fixed in 6.7.1.
Published: 2026-02-20
Score: 6.9 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Denial of Service
Action: Immediate Patch
AI Analysis

Impact

An infinite loop occurs when the pypdf library processes the children of a TreeObject, typically used for outlines in a PDF. The loop consumes CPU resources and can cause the parsing application to hang or crash, resulting in a denial of service. This weakness is classified as a logical flaw that can lead to application unavailability, potentially affecting services that rely on PDF processing.

Affected Systems

The vulnerability applies to the pypdf Python library for all versions prior to 6.7.1, released by the py-pdf project. Any system or application that imports pypdf and parses untrusted PDF files is potentially affected.

Risk and Exploitability

The CVSS score of 6.9 indicates a moderate impact. The EPSS score of less than 1% suggests a very low likelihood of exploitation in the wild, and the issue is not listed as a known exploited vulnerability. An attacker would need to supply a crafted PDF that contains a malicious TreeObject to a vulnerable application; the attack vector is inferred to be via file upload or remote processing of untrusted PDFs. Exploitation relies on the ability to load the PDF within an environment where resource limits are not tightly controlled, and the loop can be triggered without additional credentials.

Generated by OpenCVE AI on April 17, 2026 at 17:09 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade the pypdf library to version 6.7.1 or newer, which contains the loop‑fix.
  • Validate or sanitize PDF input before feeding it to pypdf, rejecting files that contain malformed or excessively nested TreeObjects.
  • Run PDF parsing in a restricted or sandboxed process with CPU and memory limits to prevent a single malicious file from exhausting host resources.

Generated by OpenCVE AI on April 17, 2026 at 17:09 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-996q-pr4m-cvgq pypdf has a possible infinite loop when processing TreeObject
History

Tue, 24 Feb 2026 19:15:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Tue, 24 Feb 2026 15:30:00 +0000

Type Values Removed Values Added
First Time appeared Pypdf Project
Pypdf Project pypdf
CPEs cpe:2.3:a:pypdf_project:pypdf:*:*:*:*:*:*:*:*
Vendors & Products Pypdf Project
Pypdf Project pypdf
Metrics cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H'}

cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H'}


Mon, 23 Feb 2026 15:00:00 +0000

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

Sat, 21 Feb 2026 12:15:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H'}

threat_severity

Moderate


Fri, 20 Feb 2026 21:30:00 +0000

Type Values Removed Values Added
Description pypdf is a free and open-source pure-python PDF library. Prior to 6.7.1, an attacker who uses this vulnerability can craft a PDF which leads to an infinite loop. This requires accessing the children of a TreeObject, for example as part of outlines. This vulnerability is fixed in 6.7.1.
Title pypdf has a possible infinite loop when processing TreeObject
Weaknesses CWE-835
References
Metrics cvssV4_0

{'score': 6.9, 'vector': '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'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-02-24T18:34:30.680Z

Reserved: 2026-02-17T03:08:23.490Z

Link: CVE-2026-27024

cve-icon Vulnrichment

Updated: 2026-02-24T18:34:22.895Z

cve-icon NVD

Status : Analyzed

Published: 2026-02-20T22:16:28.687

Modified: 2026-02-24T15:19:23.167

Link: CVE-2026-27024

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-02-20T21:10:07Z

Links: CVE-2026-27024 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-04-17T17:15:23Z

Weaknesses