6.6medium
pypdf: Manipulated FlateDecode XFA streams can exhaust RAM
- Severity
- 6.6medium CVSS:4.0 by GitHub_M
- Exploit likelihood
- 0.41% (higher than 37% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-x7hp-r3qg-r3cjPYSEC-2026-3027
Description
pypdf is a free and open-source pure-python PDF library. Prior to 6.7.3, 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`. This has been fixed in pypdf 6.7.3. As a workaround, apply the patch manually.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| py-pdf pypdf | < 6.7.3, before 6.7.3 | CVE List, NVD |
| pypdf (PyPI) | before 6.7.3 | GitHub Advisory Database, PyPA Advisory Database |
All scores
| GitHub_M | 6.6medium CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:U |
| GitHub | medium CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:U |
| NVD | 7.5high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| PyPA Advisory Database | Not scored CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:U |
Classification
SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial.
What each source says
CVE List
pypdf is a free and open-source pure-python PDF library. Prior to 6.7.3, 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`. This has been fixed in pypdf 6.7.3. As a workaround, apply the patch manually.
GitHub Advisory Database
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.
Workarounds
If projects cannot upgrade yet, consider applying the changes from PR #3658.
NVD (es)
pypdf es una biblioteca PDF de Python puro, gratuita y de código abierto. Antes de la versión 6.7.3, un atacante que utiliza esta vulnerabilidad puede crear un PDF que provoca el agotamiento de la RAM. Esto requiere acceder a la propiedad 'xfa' de un lector o escritor y que el flujo correspondiente esté comprimido usando '/FlateDecode'. Esto ha sido corregido en pypdf 6.7.3. Como solución alternativa, aplique el parche manualmente.
References
| https://github.com/py-pdf/pypdf/security/advisories/GHSA-x7hp-r3qg-r3cj | patch, vendor-advisory, web | |
| https://github.com/py-pdf/pypdf/pull/3658 | issue-tracking, patch, web | |
| https://github.com/py-pdf/pypdf/commit/7a4c8246ed48d9d328fb596942271da47b6d109c | patch, web | |
| https://github.com/py-pdf/pypdf/releases/tag/6.7.3 | product, release-notes, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2026-27888 | advisory | |
| https://github.com/py-pdf/pypdf | package | |
| https://pypi.org/project/pypdf | package | |
| https://github.com/advisories/GHSA-x7hp-r3qg-r3cj | advisory | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-27888 changed 2026-06-23 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-x7hp-r3qg-r3cj changed 2026-07-13 | CC-BY-4.0 |
| NVD | CVE-2026-27888 changed 2026-11-02 | Public domain |
| PyPA Advisory Database | PYSEC-2026-3027 changed 2026-07-13 | CC-BY-4.0 |