
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-112392 is a NULL pointer dereference and out-of-bounds read vulnerability in Pillow, the Python imaging library, affecting all versions prior to 13.0.0 (≤ 12.3.0). The flaw resides in the ImagingExpand() function in src/libImaging/Filter.c, which fails to handle zero-size images when rank-based filters (median, minimum, maximum, or rank filter) are applied, causing a native process crash (SIGSEGV). It was disclosed on October 17–19, 2026, with a fix released in Pillow 13.0.0. The vulnerability carries a CVSS v4.0 base score of 8.2 (High) (GitHub Advisory, Red Hat CVE).
The root cause is classified as CWE-476 (NULL Pointer Dereference) and CWE-125 (Out-of-bounds Read). When ImagingExpand() processes a zero-width or zero-height image, it allocates a non-empty output buffer but then attempts to replicate edge pixels by reading imIn->image[y][0] — however, ImagingAllocateArray() leaves all line pointers NULL for zero-size images, so the first read dereferences a NULL pointer and kills the process with SIGSEGV. Zero-size images are easily produced via ordinary Pillow API calls such as Image.crop() with equal left/right or top/bottom coordinates, Image.new() with a zero dimension, or by opening a multi-page TIFF file whose second IFD declares ImageLength = 0. The fix, committed in PR #10130, adds an early return in ImagingExpand() that returns a zeroed image of the expanded size when the input has zero width or height, mirroring similar guards in BoxBlur.c and Offset.c (GitHub Advisory, Fix Commit).
Successful exploitation causes a denial of service by crashing the entire embedding process (e.g., a web worker or pipeline process) with SIGSEGV rather than raising a Python exception, disrupting service to legitimate users. The faulting access is a read at address 0 (or a small negative offset), so there is no memory disclosure or corruption beyond the crash — confidentiality and integrity are not affected. Applications that accept user-supplied crop coordinates or uploaded image files (particularly multi-page TIFFs) and subsequently apply median, minimum, maximum, or rank filters are directly at risk (GitHub Advisory).
There is no public proof-of-concept exploit code and no evidence of in-the-wild exploitation as of the disclosure date. The vulnerability is remotely exploitable without authentication or privileges, requiring only that an attacker can supply a crafted image (e.g., a zero-dimension crop or a specially crafted multi-page TIFF) to an application that applies rank-based filters. The EPSS score is 0.0, and the vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog (Red Hat CVE, GitHub Advisory).
MedianFilter, MinFilter, MaxFilter, or RankFilter to user-supplied images.(3, 0, 3, 10)) to produce a 0×10 image via Image.crop().ImageLength = 0 (a minimal two-page TIFF of ~384 bytes is sufficient).image.filter(ImageFilter.MedianFilter(3)) (or similar), which invokes ImagingExpand() → NULL pointer dereference → SIGSEGV, killing the worker process and causing a denial of service (GitHub Advisory).ImageLength = 0 in the second IFD); unusual patterns of requests targeting image processing endpoints followed by service unavailability.ImagingExpand in the stack trace (GitHub Advisory).Upgrade Pillow to version 13.0.0 or later, which includes the fix in src/libImaging/Filter.c (commit 443e313) that adds an early return for zero-size images in ImagingExpand() (Pillow 13.0.0 Release, Fix Commit). If immediate patching is not possible, implement input validation at the application layer to reject images with zero width or height before passing them to any rank-based filter (MedianFilter, MinFilter, MaxFilter, RankFilter). A Python-level guard such as if 0 in image.size: return image.copy() in the filter call path would also prevent the crash, though the C-level fix in 13.0.0 is the preferred solution (GitHub Advisory).
Fix availability across major Linux distributions and their releases.
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."