# CVE-2021-34552: Buffer Overflow in Pillow

- Severity: Critical 9.8 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/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): 2.68%, higher than 86% of CVEs (2026-12-01)
- Published: 2021-07-13T00:00:00.000Z
- Modified: 2026-09-08T08:48:18.546Z
- Also known as: GHSA-7534-mm45-c74v, BIT-PILLOW-2021-34552, PYSEC-2021-331
- Weaknesses: CWE-120
- Assigned by: mitre

## Description

Pillow through 8.2.0 and PIL (aka Python Imaging Library) through 1.1.7 allow an attacker to pass controlled parameters directly into a convert function to trigger a buffer overflow in Convert.c.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- pillow (PyPI): before 8.3.0
- python pillow: from 1.0 up to 1.1.7; from 1.2 up to 8.2.0
- debian debian_linux: 9.0
- fedoraproject fedora: 33; 34
- pillow (Bitnami): from 1.0.0 before 1.1.8; from 1.2.0 before 8.2.1

## Every score

- GitHub: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- GitHub: CVSS:4.0 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- NVD: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 7.5 High `AV:N/AC:L/Au:N/C:P/I:P/A:P`
- Bitnami Vulnerability Database: rating Critical

## References

- <https://pillow.readthedocs.io/en/stable/releasenotes/index.html> (advisory, release-notes, vendor-advisory, web)
- <https://pillow.readthedocs.io/en/stable/releasenotes/8.3.0.html#buffer-overflow> (advisory, release-notes, vendor-advisory, web)
- <https://lists.debian.org/debian-lts-announce/2021/07/msg00018.html> (advisory, mailing-list, third-party-advisory, web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/7V6LCG525ARIX6LX5QRYNAWVDD2MD2SV/> (vendor-advisory, web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/VUGBBT63VL7G4JNOEIPDJIOC34ZFBKNJ/> (vendor-advisory, web)
- <https://security.gentoo.org/glsa/202211-10> (advisory, third-party-advisory, vendor-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-34552> (advisory, web)
- <https://github.com/python-pillow/Pillow/pull/5567> (web)
- <https://github.com/python-pillow/Pillow/commit/31c473898c29d1b7cb6555ce67d9503a4906b83f> (web)
- <https://github.com/advisories/GHSA-7534-mm45-c74v> (advisory)
- <https://github.com/pypa/advisory-database/tree/main/vulns/pillow/PYSEC-2021-331.yaml> (web)
- <https://github.com/python-pillow/Pillow> (package)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/7V6LCG525ARIX6LX5QRYNAWVDD2MD2SV> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/VUGBBT63VL7G4JNOEIPDJIOC34ZFBKNJ> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/7V6LCG525ARIX6LX5QRYNAWVDD2MD2SV/> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/VUGBBT63VL7G4JNOEIPDJIOC34ZFBKNJ/> (web)

## Sources

- CVE List: [CVE-2021-34552](https://www.cve.org/CVERecord?id=CVE-2021-34552), CVE Terms of Use, modified 2024-08-04
- GitHub Advisory Database: [GHSA-7534-mm45-c74v](https://github.com/advisories/GHSA-7534-mm45-c74v), CC-BY-4.0, modified 2024-10-09
- NVD: [CVE-2021-34552](https://nvd.nist.gov/vuln/detail/CVE-2021-34552), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2021-331](https://osv.dev/vulnerability/PYSEC-2021-331), CC-BY-4.0, modified 2023-12-06
- Bitnami Vulnerability Database: [BIT-PILLOW-2021-34552](https://osv.dev/vulnerability/BIT-PILLOW-2021-34552), Apache-2.0, modified 2026-09-08

---

Page: https://cve.day/CVE-2021-34552 · Whole record: https://cve.day/CVE-2021-34552.json · Rebuilt by cve.day 2026-11-25T22:58:02.601Z
