CVE-2026-96778: Pillow: Heap buffer overflow writing JPEG comment after ICC profile fills buffer
Vulnerability summary
CVE-2026-96778 is a high (CVSS 8.8) Out-of-bounds Write vulnerability in python-pillow pillow. EPSS estimates a 0.45% chance of exploitation in the next 30 days, higher than 39.4% of scored vulnerabilities.
Not severe (CVSS 7.7, network access); no exploitation reported by the 5 checked sources
Source freshness unavailable
How is this decided?Advisory lineage
Upstream 0 · Downstream 1 · Related 1Timeline
- 21-10-2026PublishedVulnerability first disclosed.
- 28-10-2026Last modifiedVulnerability information updated.
Description
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.
CVSS metrics
9 scores · 7 sources · 2 versions- NVDNIST7.7HighCVSS: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
- OSV · PypiEcosystem advisory · calculated7.7HighCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
- OSV · WolfiEcosystem advisory · calculated7.7HighCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
- OSV · ChainguardEcosystem advisory · calculated7.7HighCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
- OSV · UbuntuEcosystem advisory · calculated7.7HighCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
- OSV · DebianEcosystem advisory · calculated8.8HighCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- OSV · UbuntuEcosystem advisory · calculated8.8HighCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS trend
Probability
0.45%
Chance of exploitation in the next 30 days
Percentile
39%
Versus all other CVEs
30-day change
Change unavailable
Change unavailable
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Known conditions: network-reachable, no authentication, user interaction (CVSS vector). Other conditions: not stated in public data.
Chainguard20 products
- mlflowAll versions (No fix recorded) | < 3.17.2-r2
- mlflow-fipsAll versions (No fix recorded) | < 3.17.2-r3
- nemo-gymAll versions (No fix recorded) | < 0.5.0_rc0_git20260729-r6
- nemo-rl-cuda-13.0All versions (No fix recorded) | < 0.7.0-r11
- nemo-rl-cuda-13.0-automodelAll versions (No fix recorded) | < 0.7.0-r11
Wolfi3 products
- mlflowAll versions (No fix recorded)
- open-webuiAll versions (No fix recorded)
- py3.10-pillowAll versions (No fix recorded)
Ubuntu2 products
- pillowAll versions (No fix recorded)
- pillow-python2All versions (No fix recorded)
Debian1 product
- pillowAll versions (No fix recorded)
PyPI1 product
- pillow≥ 9.4.0, < 13.0.0
Python1 product
- pillow≥ 9.4.0, < 13.0.0
Python-pillow1 product
- pillow≥ 9.4.0, < 13.0.0
7 vendors · 29 products
References
10 links- github.com/python-pillow/Pillow/security/advisories/GHSA-g7cr-3p24-7wf7X Refsource CONFIRMWEBAdvisoryREPORTVendor Advisory
- github.com/python-pillow/Pillow/commit/02561b8dc6117d5670d4b469fecdd02c70854f9bX Refsource MISCWEBFIXPatch