VYPR
High severityNVD Advisory· Published Mar 19, 2021· Updated Aug 3, 2024

CVE-2021-25293

CVE-2021-25293

Description

An issue was discovered in Pillow before 8.1.1. There is an out-of-bounds read in SGIRleDecode.c.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

Pillow before 8.1.1 has an out-of-bounds read in SGIRleDecode.c, enabling denial of service or memory disclosure via crafted SGI images.

Vulnerability

Overview

CVE-2021-25293 is an out-of-bounds read vulnerability in the SGI RLE decoder of the Pillow image processing library (versions prior to 8.1.1). The root cause is the absence of bounds checking in the expandrow function within SGIRleDecode.c. When decoding RLE-compressed scanlines, the code reads bytes from the source buffer without verifying that the pointer remains within the allocated memory region, leading to out-of-bounds access [1][2].

Exploitation

An attacker can exploit this vulnerability by supplying a specially crafted SGI image file. The attack vector is network-based with low complexity, requires no privileges, and only needs user interaction (e.g., opening the image) [3]. By manipulating the RLE offset and length tables in the SGI header, the attacker can cause the decoder to read beyond the intended buffer boundaries during the RLE chunk processing [1][2].

Impact

Successful exploitation can result in a denial of service (application crash) or, in some cases, the disclosure of sensitive memory contents (information leakage) [3][4]. The CVSS score reflects a medium severity, with potential for partial confidentiality and availability impacts.

Mitigation

The issue was addressed in Pillow version 8.1.1, released in March 2021. Users are strongly advised to upgrade to this version or later. No workarounds are available; updating the library is the only reliable fix [4].

AI Insight generated on May 21, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
PillowPyPI
>= 4.3.0, < 8.1.18.1.1

Affected products

11

Patches

0

No patches discovered yet.

Vulnerability mechanics

AI mechanics synthesis has not run for this CVE yet.

References

7

News mentions

0

No linked articles in our index yet.