Heap-based buffer overflow in Pillow - #VU158900

 

Heap-based buffer overflow in Pillow - #VU158900

Published: November 3, 2026


Vulnerability identifier: #VU158900
CSH Severity: Medium
CVSS v4: 8.7 [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]
CVE-ID: N/A
CWE-ID: CWE-122
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote attacker to corrupt heap memory and cause a denial of service.

The vulnerability exists due to a heap-based buffer overflow in Pillow's libtiff TIFF encoder when saving images whose retained metadata specifies oversized scanlines and enables Predictor=2. A remote attacker can upload a crafted image that causes libtiff's horizontal differencing operation to rewrite data beyond the image-sized row buffer, corrupting the heap and aborting the process.

The overwritten values are byte-wise differences of existing heap contents; the attacker controls the extent and repetition of the writes, but not their data directly.


Affected software

Pillow

Remediation

Install security update from vendor's website.

Pillow - update to 13.0.0

External References

Related Security Bulletins