# CVE-2021-28675

- Priority: **Routine**
- Reason: Not severe (CVSS 5.5, local access); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2021-06-02 · Modified: 2024-08-03
- Aliases: ALPINE-CVE-2021-28675, GHSA-g6rj-rv7j-xwp4, BIT-pillow-2021-28675, PYSEC-2021-139, UBUNTU-CVE-2021-28675, DEBIAN-CVE-2021-28675
- Record: https://cvemate.com/vulnerability/CVE-2021-28675 · JSON: https://cvemate.com/vulnerability/CVE-2021-28675/json

## Description

```text
An issue was discovered in Pillow before 8.2.0. PSDImagePlugin.PsdImageFile lacked a sanity check on the number of input layers relative to the size of the data block. This could lead to a DoS on Image.open prior to Image.load.
```

## Signals

- CVSS: 5.5 medium (v3.1, NVD) CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
- EPSS: 1.186%, percentile 68.892%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected

- alpine py3-pillow (Alpine Linux): \< 8.2.0-r0
- debian pillow (Debian): \< 8.1.2+dfsg-0.2
- ubuntu pillow (Ubuntu): \< 2.3.0-1ubuntu3.4+esm5 \| \< 3.1.2-0ubuntu1.6+esm3 \| \< 5.1.0-1ubuntu0.6 \| \< 7.0.0-4ubuntu0.4
- ubuntu pillow-python2 (Ubuntu): All versions (No fix recorded)
- fedoraproject fedora: 33
- PyPI pillow (PyPI): \< 8.2.0
- python pillow: \< 8.2.0

## References

- <https://pillow.readthedocs.io/en/stable/releasenotes/8.2.0.html#cve-2021-28675-fix-dos-in-psdimageplugin>
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MQHA5HAIBOYI3R6HDWCLAGFTIQP767FL/>
- <https://security.gentoo.org/glsa/202107-33>
- <https://security.alpinelinux.org/vuln/CVE-2021-28675>
- <https://nvd.nist.gov/vuln/detail/CVE-2021-28675>
- <https://github.com/python-pillow/Pillow/pull/5377/commits/22e9bee4ef225c0edbb9323f94c26cee0c623497>
- <https://github.com/advisories/GHSA-g6rj-rv7j-xwp4>
- <https://github.com/pypa/advisory-database/tree/main/vulns/pillow/PYSEC-2021-139.yaml>
- <https://github.com/python-pillow/Pillow>
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/MQHA5HAIBOYI3R6HDWCLAGFTIQP767FL>
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/MQHA5HAIBOYI3R6HDWCLAGFTIQP767FL/>
- <https://ubuntu.com/security/CVE-2021-28675>
- <https://ubuntu.com/security/notices/USN-4963-1>
- <https://www.cve.org/CVERecord?id=CVE-2021-28675>
- <https://ubuntu.com/security/notices/USN-8135-1>
- <https://security-tracker.debian.org/tracker/CVE-2021-28675>

---

Data as of 2026-12-05T04:58:48.600Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
