- Home
- Vulnerabilities
- CVE-2026-96778
CVE-2026-96778
Pillow: Heap buffer overflow writing JPEG comment after ICC profile fills buffer
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.
Affected products and versions
python-pillow (1 line(s))
| Product | Versions | Fixed in | Source |
|---|---|---|---|
| Pillow | Versions not specified | — | CNA (vendor or assigner) |
Pypi (1 line(s))
| Product | Versions | Fixed in | Source |
|---|---|---|---|
| pillow | from 9.4.0 (included) to 13.0.0 (excluded) |
13.0.0 |
GitHub Advisory |
Python (1 line(s))
| Product | Versions | Fixed in | Source |
|---|---|---|---|
| Pillow | from 9.4.0 (included) to 13.0.0 (excluded) |
— | NVD |
Fix
Upgrade — PyPI/pillow 13.0.0official source
Source : GitHub Advisory
Workaround
No workaround provided.
Check whether you are affected
Exploit reported by sources
These links are tagged “exploit” by the NVD or CVE.org. We have neither verified nor copied them; open with care.
Timeline
- — CVE published (cve)
- — CERT-FR advisory (certfr:CERTFR-2026-AVI-1486)
- — CERT-FR advisory (certfr:CERTFR-2026-AVI-1527)
CERT-FR advisories
- CERTFR-2026-AVI-1527 — Multiples vulnérabilités dans VMware Tanzu Greenplum (13 novembre 2026) 13 Nov 2026
- CERTFR-2026-AVI-1486 — Multiples vulnérabilités dans les produits VMware (09 novembre 2026) 9 Nov 2026
- GHSA-g7cr-3p24-7wf7 — Pillow: Heap buffer overflow writing JPEG comment after ICC profile fills buffer 22 Oct 2026
References
- https://github.com/python-pillow/Pillow/security/advisories/GHSA-g7cr-3p24-7wf7exploit
- https://github.com/python-pillow/Pillow/pull/10124x_refsource_MISC
- https://github.com/python-pillow/Pillow/commit/02561b8dc6117d5670d4b469fecdd02c70854f9bx_refsource_MISC
- https://github.com/python-pillow/Pillow/releases/tag/13.0.0x_refsource_MISC
- https://nvd.nist.gov/vuln/detail/CVE-2026-96778ADVISORY
- https://github.com/python-pillow/PillowPACKAGE
Data provenance
- Status
- NVD
- Publication date
- NVD
- Description
- CNA (vendor or assigner)
- CVSS score
- NVD
- Weakness (CWE)
- NVD
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H(CVSS 3.1, NVD)- Weakness
- CWE-787 · Corruption mémoire