Out-of-bounds read in Pillow - CVE-2026-54058

 

Out-of-bounds read in Pillow - CVE-2026-54058

Published: July 7, 2026


Vulnerability identifier: #VU137006
CSH Severity: High
CVSS v4.0: CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:H/VI:N/VA:H/SC:N/SI:N/SA:N/E:U/U:Amber
CVE-ID: CVE-2026-54058
CWE-ID: CWE-125
Exploitation vector: Remote access
Exploit availability: No public exploit available
Vendor: Alex Clark and Contributors
Affected software:
Pillow

Detailed vulnerability description

The vulnerability allows a remote attacker to disclose sensitive information or cause a denial of service.

The vulnerability exists due to an out-of-bounds read in the PyImaging_MapBuffer mmap path used with the McIdas AREA plugin when processing a crafted image file opened from a filename. A remote attacker can supply a specially crafted McIdas AREA image with an undersized row stride to disclose sensitive information or cause a denial of service.

The issue is reachable when Pillow memory-maps an uncompressed raw tile in a mode listed in Image._MAPMODES, and pixel access operations such as Image.tobytes(), getpixel, convert, or save trigger the read.


How to mitigate CVE-2026-54058

Install security update from vendor's website.

Sources