CVE-2020-6817
HIGH 7.5CVSS 3.1regular expression denial-of-service (ReDoS) in Bleach
bleach.clean behavior parsing style attributes could result in a regular expression denial of service (ReDoS). Calls to bleach.clean with an allowed tag with an allowed style attribute are vulnerable to ReDoS. For example, bleach.clean(..., attributes={'a': ['style']}).
- Published
- 16 Feb 2023
- Last modified
- 10 Sep 2026
- Assigned by
- security@mozilla.org
- NVD status
- Modified
- Weakness
- CWE-1333CWE-400
- Also known as
- GHSA-vqhp-cxgc-6wmmPYSEC-2020-340SNYK-PYTHON-BLEACH-561754
- Sources
- NVDJSONOSV GHSA-vqhp-cxgc-6wmmJSONOSV PYSEC-2020-340JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| OSV | GitHub | CVSS 4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N | |
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | HIGH 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| NVD | 134c704f-9b21-4f2e-91b3-4a467353bcc0 (Secondary) | CVSS 3.1 | HIGH 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| OSV | GitHub | CVSS 3.1 | HIGH 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | mozilla | bleachcpe:2.3:a:mozilla:bleach:*:*:*:*:*:*:*:* |
< 3.1.4 | 3.1.4 |
| OSV | PyPI | bleach | < 3.1.4 | 3.1.4 |
References
- https://bugzilla.mozilla.org/show_bug.cgi?id=1623633 · Exploit, Issue Tracking, WEB, REPORT
- https://github.com/mozilla/bleach/security/advisories/GHSA-vqhp-cxgc-6wmm · Vendor Advisory, WEB, ADVISORY
- https://nvd.nist.gov/vuln/detail/CVE-2020-6817 · ADVISORY
- https://github.com/mozilla/bleach · PACKAGE
- https://github.com/mozilla/bleach/releases/tag/v3.1.4 · WEB
- https://github.com/pypa/advisory-database/tree/main/vulns/bleach/PYSEC-2020-340.yaml · WEB
- https://snyk.io/vuln/SNYK-PYTHON-BLEACH-561754 · WEB, ADVISORY
- https://blog.r2c.dev/posts/finding-python-redos-bugs-at-scale-using-dlint-and-r2c/ · ARTICLE
History
- 25 Nov 2026 20:35 UTC · NVD: first stored (published 16 Feb 2023)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 30 Mar 2020)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 30 Mar 2020)