PT-2026-117669
CVE-2026-112403
·
Published
2026-10-17
·
Updated
2026-11-12
Description by
CVSS 3.1
9.8
CriticalMetricsAV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Name of the Vulnerable Software and Affected Versions
Pillow versions prior to 13.0.0
Description
The JPEG decoder in Pillow fails to verify the actual output width and component count after a scaling request is made. When an application uses
draft() or thumbnail() to request downscaling of an 8-bit lossless SOF3 JPEG, and the software is linked to libjpeg-turbo 3.x, the requested downscaling geometry may be ignored. This occurs because ImagingJpegDecode() does not compare the output dimensions from libjpeg against the allocated buffer size in setimage(). Consequently, a full-width scanline can be written into a buffer sized for a smaller draft scale, leading to a heap memory corruption. This can result in a process crash or potentially allow arbitrary code execution. The issue is specifically triggered when the image width and height are at least 1024 pixels and a scaling factor of 2 or more is selected.Recommendations
Update Pillow to version 13.0.0.
As a temporary workaround, avoid using the
draft() or thumbnail() functions on untrusted JPEG images.
Restrict the use of the thumbnail() function by setting the reducing gap parameter to None to avoid the vulnerable code path.Exploitability
Exploit
Fix
Impacts
Vendors
Affected products
Found an issue in the description? Have something to add? Feel free to write us 👾