Bug 2558575 (CVE-2026-96639)

Summary: CVE-2026-96639 pillow: Pillow multi-frame loaders can reuse stale native image storage after mode transitions
Product: [Other] Security Response Reporter: OSIDB Bzimport <bzimport>
Component: vulnerabilityAssignee: Product Security <prodsec-ir-bot>
Status: NEW --- QA Contact:
Severity: urgent Docs Contact:
Priority: urgent    
Version: unspecifiedCC: alinfoot, anthomas, bbrownin, dschmidt, dtrifiro, ehelms, ggainey, jlanda, jpasqual, juwatts, kshier, mdellweg, mhulan, mwoodson, nmoumoul, osousa, pcreech, rbobbitt, rchan, rhel-process-autobot, simaishi, smallamp, stcannon, tmalecek, watson-tool-maintainers, weaton, yguenane
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 processing multi-frame images that transition between different color modes, Pillow reuses an undersized native memory buffer without verifying that its format matches the subsequent frame. A remote attacker can exploit this flaw by providing a specially crafted multi-frame image file, causing an out-of-bounds memory write. Successful exploitation can lead to arbitrary code execution or a Denial of Service (DoS) resulting from an application crash.
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-10-21 21:24:53 UTC
Pillow is a Python imaging library. From 11.0.0 until 13.0.0, multi-frame loaders can retain an ImagingCore allocation created for a narrow frame mode while a later frame of the same dimensions changes the logical mode and decoder tiles to wider RGB or CMYK data. ImageFile.load_prepare() reuses the stale native storage because _im is non-null without verifying that its mode and size still match. Crafted PSD, MPO, DCX, or MIC frame transitions can then write wider pixels into the narrow allocation, causing native out-of-bounds writes and crashes. The MPO path can also cause a native over-read and, in demonstrated runtime-specific profiles, command execution. This issue is fixed in version 13.0.0.