CVE-2021-23437Python Pillow
High 7.5 No auth needed
Follow: this CVE · Python · Python Pillow We alert you by email or Slack (account required).
- Priority
- 60
- CVSS 3.1
- 7.5
- EPSS
- 3.2% probability of exploitation in 30 days · percentile 89
- Auth required
- No
- Published
- Sep 3, 2021
- Updated
- Jun 17, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-125
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
What happens
The package pillow 5.2.0 and before 8.3.2 are vulnerable to Regular Expression Denial of Service (ReDoS) via the getrgb function.
What to do
- Apply the vendor's security update for Pillow.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| PyPI | pillow |
≥ 5.2.0 < 8.3.2 |
8.3.2 |
pip install "pillow>=8.3.2" |
| PyPI | pillow |
< 8.3.2 |
8.3.2 |
pip install "pillow>=8.3.2" |
Per OSV / GitHub Advisories (GHSA-98vv-pw6r-q6q4, PYSEC-2021-317). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| python | pillow | ≥ 5.2.0 < 8.3.2 |
| fedoraproject | fedora | 33 |
| fedoraproject | fedora | 34 |
Official advisories
- python313-Pillow-12.3.0-1.1 on GA media · SUSE · openSUSE-SU-2026:11261-1 · Jul 12, 2026 Critical
Vendor, CERT and distribution advisories that name this CVE. Original titles.
Official sources
References
Links published by the sources. Open them with care.
- github.com Patch Third Party Advisory
- lists.debian.org
- lists.fedoraproject.org
- lists.fedoraproject.org
- pillow.readthedocs.io Release Notes Vendor Advisory
- security.gentoo.org Third Party Advisory
- snyk.io Exploit Patch Release Notes