All reports
Medium

pypdf can exhaust RAM via manipulated LZWDecode streams

Affected versions

Version ranges need review.

PyPIpypdf
Affected versions
<6.1.3
Fixed version
6.1.3
PyPIpypdf
Affected versions
< 6.1.3
Fixed version
6.1.3
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported

Exploitation

CVE-2025-62708

Probability of exploitation in the next 30 days: 0.44%

FIRST EPSS · 2026-11-21

Description

Impact

An attacker who uses this vulnerability can craft a PDF which leads to large memory usage. This requires parsing the content stream of a page using the LZWDecode filter.

Patches

This has been fixed in pypdf==6.1.3.

Workarounds

If you cannot upgrade yet, consider applying the changes from PR #3502.

Links

Credits

  • tylzh97
  • stefan6419846