# CVE-2026-96641: Pillow: Reachable undefined behavior in native integer operations, potentially leading to denial of service or logic integrity compromise

- Severity: Medium 6.5 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.36%, higher than 32% of CVEs (2026-12-02)
- Published: 2026-10-21T20:51:24.388Z
- Modified: 2026-10-29T10:56:07.449Z
- Also known as: GHSA-4rm8-3hmm-39fg, BIT-PILLOW-2026-96641, PYSEC-2026-4340
- Weaknesses: CWE-190
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Pillow is a Python imaging library. Prior to 13.0.0, PILfont text-width accumulation in src/_imaging.c checks positive glyph advances against INT_MAX but does not check negative advances against INT_MIN. Repeating a signed 16-bit advance of -32768 can therefore execute a signed C integer overflow in xsize += dx, producing a large positive width from a negative mathematical result. Applications that use getlength(), getsize(), or derived layout, quota, serialization, or allocation calculations can experience logic-integrity errors or resource consumption, while the high-level mask path commonly retains a decompression-bomb check. This issue is fixed in version 13.0.0.

(As written by CVE List.)

## Affected

- python-pillow Pillow: < 13.0.0
- pillow (PyPI): before 13.0.0
- python pillow: before 13.0.0
- pillow (Bitnami): before 13.0.0

## Every score

- GitHub_M: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- GitHub: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- PyPA Advisory Database: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- Bitnami Vulnerability Database: rating Medium

## References

- <https://github.com/python-pillow/Pillow/security/advisories/GHSA-4rm8-3hmm-39fg> (advisory, vendor-advisory, web)
- <https://github.com/python-pillow/Pillow/pull/10010> (issue-tracking, report, web)
- <https://github.com/python-pillow/Pillow/commit/80de4be9e38d3a6148dd4d8491eb80cd12b760a4> (fix, patch, web)
- <https://github.com/python-pillow/Pillow/releases/tag/13.0.0> (advisory, article, release-notes, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-96641> (advisory, web)
- <https://github.com/python-pillow/Pillow> (package)

## Sources

- CVE List: [CVE-2026-96641](https://www.cve.org/CVERecord?id=CVE-2026-96641), CVE Terms of Use, modified 2026-10-28
- GitHub Advisory Database: [GHSA-4rm8-3hmm-39fg](https://github.com/advisories/GHSA-4rm8-3hmm-39fg), CC-BY-4.0, modified 2026-10-29
- NVD: [CVE-2026-96641](https://nvd.nist.gov/vuln/detail/CVE-2026-96641), Public domain, modified 2026-10-28
- PyPA Advisory Database: [PYSEC-2026-4340](https://osv.dev/vulnerability/PYSEC-2026-4340), CC-BY-4.0, modified 2026-10-29
- Bitnami Vulnerability Database: [BIT-PILLOW-2026-96641](https://osv.dev/vulnerability/BIT-PILLOW-2026-96641), Apache-2.0, modified 2026-10-29

---

Page: https://cve.day/CVE-2026-96641 · Whole record: https://cve.day/CVE-2026-96641.json · Rebuilt by cve.day 2026-11-25T22:59:46.695Z
