Bug 2565602 (CVE-2026-112902)

Summary: CVE-2026-112902 Pillow: Memory disclosure and segfault in libtiff encoder via crafted TIFF tags
Product: [Other] Security Response Reporter: OSIDB Bzimport <bzimport>
Component: vulnerabilityAssignee: Product Security <prodsec-ir-bot>
Status: NEW --- QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: alinfoot, anpicker, aprice, bbrownin, cmyers, dfreiber, dnakabaa, doconnor, drow, dschmidt, dtrifiro, ebourniv, ehelms, hasun, ilpinto, jburrell, jfula, jlanda, jmitchel, jowilson, jpasqual, jsamir, juwatts, jwong, kaycoth, kshier, lblicha, lcouzens, ltomasbo, mhayden, mhulan, mwoodson, nyancey, oezr, ogajduse, ometelka, osousa, ptisnovs, rbobbitt, rchan, rhel-process-autobot, sbunciak, sdoran, simaishi, smallamp, stcannon, syedriko, tguha, vkumar, watson-tool-maintainers, weaton, xdharmai, yguenane, ykashtan, zhunting
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
A flaw was found in Pillow. When saving an image in the TIFF format, Pillow incorrectly forwards unknown metadata tags to the underlying image processing library. A remote attacker could exploit this flaw by providing a specially crafted image containing malicious metadata to an application that processes and re-saves it. Successful exploitation allows the attacker to read out-of-bounds memory, leading to the disclosure of sensitive process memory or causing the application to crash, resulting in a Denial of Service (DoS).
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description OSIDB Bzimport 2026-11-03 05:32:54 UTC
This is a high-severity Pillow security advisory for CVE-2026-112902. A malicious TIFF (or EXIF metadata in a JPEG/PNG/WebP) can cause Pillow to leak process memory or crash when the image is re-saved as a TIFF.

Pillow incorrectly forwards unknown TIFF tags to libtiff, assuming its own registration controls how libtiff interprets the arguments. It does not; libtiff uses its built-in definition for known tags.

As a result, a tiny crafted file—about 356 bytes in the reproducer—can make Pillow copy up to attacker-chosen amounts of worker-process memory into the output TIFF, or trigger a segmentation fault.

The vulnerable code path is triggered by an ordinary Image.open() followed by im.save(fp, "TIFF"), especially when the source image is compressed and therefore uses libtiff.

## Impact
Confidentiality: Memory contents can be disclosed in the saved TIFF metadata; the report says this can expose data from Python, libc, libtiff, libjpeg, and other linked libraries, potentially defeating ASLR.

Availability: Certain crafted tags cause a deterministic worker crash (SIGSEGV) from a sub-1 KB upload.

Scope: Services that accept image uploads and convert or re-save them as TIFF are most exposed; JPEG/PNG/WebP EXIF metadata preserved during TIFF conversion can also trigger it.

The advisory found only out-of-bounds reads, not writes.

Affected versions and fix
Item	Detail
Package	Pillow (pip)
Vulnerable versions	12.3.0 and earlier
Fixed version	13.0.0
Severity	High, CVSS v4 8.7/10
CVE / GHSA	CVE-2026-112902 / GHSA-xvh5-g6gv-559v

Upgrade Pillow to 13.0.0 or later as soon as possible. If immediate upgrade is not possible, avoid accepting and re-encoding untrusted images as TIFF, and do not pass untrusted tiffinfo/EXIF metadata into TIFF saves.