Impact
Pillow's MSP RLE decoder can decompress a small MSP image file into an unbounded amount of memory because the decoder writes run‑length output to a BytesIO stream without limiting expansion to the declared image size. This flaw means that a crafted MSP image can cause Pillow to allocate an arbitrary amount of memory when an application loads the image. The result is a denial of service through memory exhaustion, as the process or system can become unresponsive or crash. The vulnerability maps to CWE‑409 (Uncontrolled Size of Data Structure).
Affected Systems
All installations of the Python Pillow imaging library from version 4.1.0 up to but not including 13.0.0 are vulnerable. The issue was addressed in Pillow 13.0.0, which includes a fix that limits memory allocation based on the image dimensions. Users of earlier Pillow versions should review their application code to ensure it is not using these vulnerable releases.
Risk and Exploitability
The CVSS score of 8.7 indicates high severity. The EPSS score is not available, so the current probability of exploitation cannot be quantified, but the potential for denial of service exists whenever a Pillow‑based application processes untrusted MSP files. The vulnerability is not listed in CISA’s KEV catalog, suggesting no publicly confirmed exploit yet. An attacker would need to supply a malicious MSP image to an application that decodes it, such as through a web upload or a file‑processing service, which could lead to memory exhaustion and application or system downtime.
OpenCVE Enrichment