CVE-2021-23980
MEDIUM6.1EPSS 0.49%Cross-site scripting in Bleach
Published: 2/2/2021Modified: 4/28/2026
Also known as:DEBIAN-CVE-2021-23980
Description
A mutation XSS affects users calling bleach.clean with all of: svg or math in the allowed tags p or br in allowed tags style, title, noscript, script, textarea, noframes, iframe, or xmp in allowed tags the keyword argument strip_comments=False Note: none of the above tags are in the default allowed tags and strip_comments defaults to True.
Affected packages (5)
- Debian/python-bleachfrom 0, < 3.2.1-2.1
- Debian/python-bleachfrom 0, < 2.0-1+deb9u1
- Debian/python-bleachfrom 0, < 3.1.2-0+deb10u2
- PyPI/bleachfrom 0, < 3.3.0
- PyPI/bleachfrom 0, < 79b7a3c5e56a09d1d323a5006afa59b56162eb13 | from 0, < 3.3.0
CVSS scores
| Source | Version | Severity | Vector |
|---|---|---|---|
| osv | CVSS 4.0 | — | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N |
| osv | CVSS 3.1 | MEDIUM6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
References (13)
- ADVISORYhttps://nvd.nist.gov/vuln/detail/CVE-2021-23980
- ADVISORYhttps://security-tracker.debian.org/tracker/CVE-2021-23980
- PATCHhttps://github.com/mozilla/bleach
- REPORTttps://bugzilla.mozilla.org/show_bug.cgi?id=1689399
- WEBhttps://advisory.checkmarx.net/advisory/CX-2021-4303
- WEBhttps://bugzilla.mozilla.org/show_bug.cgi?id=1689399
- WEBhttps://bugzilla.mozilla.org/show_bug.cgi?id=CVE-2021-23980
- WEBhttps://cure53.de/fp170.pdf
- WEBhttps://github.com/mozilla/bleach/blob/79b7a3c5e56a09d1d323a5006afa59b56162eb13/CHANGES#L4
- WEBhttps://github.com/mozilla/bleach/commit/79b7a3c5e56a09d1d323a5006afa59b56162eb13
- WEBhttps://github.com/mozilla/bleach/security/advisories/GHSA-vv2x-vrpj-qqpq
- WEBhttps://github.com/pypa/advisory-database/tree/main/vulns/bleach/PYSEC-2021-865.yaml
- WEBhttps://pypi.org/project/bleach