---
id: CVE-2026-113793
title: 'pypdf: Possible infinite loop when removing tree items'
summary: >-
  pypdf is a free and open-source pure-python PDF library. Prior to 6.20.1,
  removing an object from a crafted cyclic PDF tree, such as an outline item,
  can enter an infinite loop and block the current process. This issue is fixed
  in versio…
severity: medium
cvss: 6
cvssVector: 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N'
cvssSource: cna
cwe:
  - CWE-835
vendor: py-pdf
product: pypdf
affected:
  - pypdf < 6.20.1
ssvc:
  exploitation: none
  automatable: 'no'
  technicalImpact: partial
  timestamp: '2026-10-28T16:51:43.110456Z'
published: '2026-10-21'
updated: '2026-10-28'
sourceUpdated: '2026-10-28T17:01:30.870Z'
source: CVEORG
sourceUrl: 'https://www.cve.org/CVERecord?id=CVE-2026-113793'
references:
  - url: 'https://github.com/py-pdf/pypdf/security/advisories/GHSA-9mx8-4j7g-633p'
    label: 'https://github.com/py-pdf/pypdf/security/advisories/GHSA-9mx8-4j7g-633p'
  - url: 'https://github.com/py-pdf/pypdf/pull/4188'
    label: 'https://github.com/py-pdf/pypdf/pull/4188'
  - url: >-
      https://github.com/py-pdf/pypdf/commit/c9c35b4471c2eb5fe078094f6c816e69d4ed25a0
    label: >-
      https://github.com/py-pdf/pypdf/commit/c9c35b4471c2eb5fe078094f6c816e69d4ed25a0
  - url: 'https://github.com/py-pdf/pypdf/releases/tag/6.20.1'
    label: 'https://github.com/py-pdf/pypdf/releases/tag/6.20.1'
  - url: 'https://github.com/py-pdf/pypdf'
  - url: 'https://github.com/advisories/GHSA-9mx8-4j7g-633p'
tags:
  - cve.org
  - osv
  - pip
  - ghsa
epss: 0.00466
epssPercentile: 0.40227
aliases:
  - GHSA-9mx8-4j7g-633p
ecosystem: pip
patched:
  - pypdf 6.20.1
ingestedAt: '2026-10-21T16:05:17.683Z'
---

## Overview

pypdf is a free and open-source pure-python PDF library. Prior to 6.20.1, removing an object from a crafted cyclic PDF tree, such as an outline item, can enter an infinite loop and block the current process. This issue is fixed in version 6.20.1.

## Affected

- `pypdf < 6.20.1`

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.

## Package advisory (CVE-2026-113793)

Affected packages:

- `pypdf < 6.20.1`

Patched in:

- `pypdf 6.20.1`

Source: https://osv.dev/vulnerability/GHSA-9mx8-4j7g-633p
