---
id: CVE-2026-27888
aliases:
  - GHSA-x7hp-r3qg-r3cj
  - PYSEC-2026-3027
title: 'pypdf: Manipulated FlateDecode XFA streams can exhaust RAM'
summary: 'pypdf: Manipulated FlateDecode XFA streams can exhaust RAM'
severity: medium
vendor: pypdf
product: pypdf
ecosystem: pip
affected:
  - pypdf < 6.7.3
patched:
  - pypdf 6.7.3
published: '2026-02-26'
updated: '2026-07-13'
source: OSV
sourceUrl: 'https://osv.dev/vulnerability/GHSA-x7hp-r3qg-r3cj'
references:
  - url: 'https://github.com/py-pdf/pypdf/security/advisories/GHSA-x7hp-r3qg-r3cj'
  - url: 'https://nvd.nist.gov/vuln/detail/CVE-2026-27888'
  - url: 'https://github.com/py-pdf/pypdf/pull/3658'
  - url: >-
      https://github.com/py-pdf/pypdf/commit/7a4c8246ed48d9d328fb596942271da47b6d109c
  - url: 'https://github.com/py-pdf/pypdf'
  - url: 'https://github.com/py-pdf/pypdf/releases/tag/6.7.3'
tags:
  - osv
  - pip
epss: 0.00644
epssPercentile: 0.48698
ingestedAt: '2026-07-13T18:58:05.037Z'
---

## Overview

### Impact
An attacker who uses this vulnerability can craft a PDF which leads to the RAM being exhausted. This requires accessing the `xfa` property of a reader or writer and the corresponding stream being compressed using `/FlateDecode`.

### Patches
This has been fixed in [pypdf==6.7.3](https://github.com/py-pdf/pypdf/releases/tag/6.7.3).

### Workarounds
If projects cannot upgrade yet, consider applying the changes from PR [#3658](https://github.com/py-pdf/pypdf/pull/3658).

## Affected packages

- `pypdf < 6.7.3`

## Remediation

Upgrade to a patched release:

- `pypdf 6.7.3`
