CVE-2026-96778

Description

A flaw was found in Pillow. A remote attacker could exploit a heap buffer overflow vulnerability to achieve arbitrary code execution or cause a Denial of Service (DoS). This issue occurs when an application re-encodes an untrusted image into JPEG format while preserving specially crafted color profile and comment metadata, causing an internal memory buffer to overflow. Successful exploitation allows adjacent memory to be overwritten, which can crash the application or permit code execution in suitable runtime environments.

Statement

Red Hat evaluates this vulnerability as having an Important severity because an unauthenticated attacker could trigger memory corruption leading to denial of service or arbitrary code execution if an exposed service processes untrusted graphics. In Red Hat ecosystems, Pillow is bundled across various containerized environments, including Red Hat OpenShift AI and Ansible Automation Platform, where background services or pipelines may ingest media files. However, exploitation requires an application workflow that explicitly re-encodes user-supplied images into JPEG format while retaining both embedded color profiles and comment metadata, which restricts the attack surface to specific image handling operations.

Mitigation

Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base, or stability.

Common Vulnerability Scoring System (CVSS) Score Details

Info alert:Important note

CVSS scores for open source components depend on vendor-specific factors (e.g. version or build chain). Therefore, Red Hat's score and impact rating can be different from NVD and other vendors. Red Hat remains the authoritative CVE Naming Authority (CNA) source for its products and services (see Red Hat classifications).

CVSS v3 Score Breakdown

Red HatNVDcve.org
Base Score8.18.8N/A
Attack VectorNetworkNetworkN/A
Attack ComplexityHighLowN/A
Privileges RequiredNoneNoneN/A
User InteractionNoneRequiredN/A
ScopeUnchangedUnchangedN/A
ConfidentialityHighHighN/A
Integrity ImpactHighHighN/A
Availability ImpactHighHighN/A

Vector

Red Hat: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

NVD: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Understanding the Weakness (CWE)

Integrity

Technical Impact: Modify Memory; Execute Unauthorized Code or Commands

Write operations could cause memory corruption. In some cases, an adversary can modify control data such as return addresses in order to execute unexpected code.

Availability

Technical Impact: DoS: Crash, Exit, or Restart

Attempting to access out-of-range, invalid, or unauthorized memory could cause the product to crash.

Other

Technical Impact: Unexpected State

Subsequent write operations can produce undefined or unexpected results.

Frequently Asked Questions

Want to get errata notifications? Sign up here.