Exploited now
Vulnerability WatchVulnerabilities, exploits & advisories — updated every 15 minutes
Alerts

Home › CVE › Python

CVE-2026-96778 — python-pillow Pillow

High · CVSS 7.7EPSS 0.6% First seen October 21, 2026
PythonVulnerabilities

Summary

Pillow is a Python imaging library. From 9.4.0 until 13.0.0, ImagingJpegEncode() in src/libImaging/JpegEncode.c can call jpeg_write_marker() for a JPEG COM comment when an ICC profile has exactly filled the 65536-byte encoder buffer. libjpeg writes one byte before checking the exhausted free_in_buffer counter, which then wraps and permits the attacker-controlled comment and subsequent compressed image data to overwrite adjacent heap memory. Re-saving an untrusted image as JPEG while preserving its ICC profile and forwarded comment can crash the process and may enable code execution in suitable runtime and heap layouts. This issue is fixed in version 13.0.0.

Description: NIST National Vulnerability Database (public domain)

Severity breakdown

High · 7.7 CVSS 4.0 base score from the CNA (github.com)

An attacker without an account can exploit this over the network if a user views or visits something, but only under specific conditions.

Attack from
the network (remotely)
Attack complexity
low (no special conditions)
Special conditions
only in some setups or conditions
Login needed
no
User action needed
yes, a user must view or visit something
Impact
high on confidentiality, integrity and availability
Impact on other systems
none

Vector CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X · CVSS 3.1 8.8 from NVD: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Weakness

Affected and fixed versions

ProductAffected versionsFixed in
python-pillow Pillow>= 9.4.0, < 13.0.0—

From the vendor's CVE record; confirm with the vendor advisory before relying on a version number.

References by type

Vendor advisories

Patches and fixed releases

Details from NVD (public domain).

Affected

  • python-pillow Pillow

What to do

  • Check whether you run an affected product or version and apply the vendor's update or mitigation.
  • Follow the vendor advisory and the references below for fixed versions and workarounds.

Frequently asked questions

What is CVE-2026-96778?

Pillow is a Python imaging library. From 9.4.0 until 13.0.0, ImagingJpegEncode() in src/libImaging/JpegEncode.c can call jpegwritemarker() for a JPEG COM comment when an ICC profile has exactly filled the 65536-byte encoder buffer. Weakness type: Out-of-bounds Write (CWE-787).

How severe is CVE-2026-96778?

CVE-2026-96778 has a CVSS 4.0 base score of 7.7 (high), from the CNA (github.com). An attacker without an account can exploit this over the network if a user views or visits something, but only under specific conditions.

Is CVE-2026-96778 being exploited?

Not as far as is known: CVE-2026-96778 is not in CISA's Known Exploited Vulnerabilities catalog as of November 26, 2026. EPSS estimates a 0.6% chance that it is exploited in the next 30 days.

Which versions are affected by CVE-2026-96778?

python-pillow Pillow >= 9.4.0, < 13.0.0.

How do I fix CVE-2026-96778?

Apply the update or mitigation in the vendor's advisory, linked on this page under Vendor advisories.

Timeline & sources

References

Related vulnerabilities & news