CVE-2021-23980
published 2023-02-16CVE-2021-23980: 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…
PriorityP423medium6.1CVSS 3.1
AVNACLPRNUIRSCCLILAN
EPSS
0.48%
38.3th percentile
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
7 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| debian | python-bleach | < python-bleach 3.2.1-2.1 (bookworm) | python-bleach 3.2.1-2.1 (bookworm) |
| mozilla | bleach | < 3.3.0 | 3.3.0 |
| mozilla | bleach | >= 0 < 3.3.0 | 3.3.0 |
| mozilla | bleach | >= 0 < 79b7a3c5e56a09d1d323a5006afa59b56162eb13 | 79b7a3c5e56a09d1d323a5006afa59b56162eb13 |
| mozilla | mozilla_bleach | >= unspecified < 3.3.0 | 3.3.0 |
| msrc | azl3_python-tensorboard_2.16.2-6_on_azure_linux_3.0 | — | — |
| msrc | cbl2_python-tensorboard_2.11.0-3_on_cbl_mariner_2.0 | — | — |
CVSS provenance
nvdv3.16.1MEDIUMCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
ghsa6.1MEDIUM
osv9.8CRITICAL
vendor_ubuntu9.8CRITICAL
vendor_debian6.1MEDIUM
vendor_msrc6.1MEDIUM
vendor_redhat6.1MEDIUM
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
OSV
python-bleach vulnerabilities
osv·2026-03-05·CVSS 9.8
CVE-2018-7753 [CRITICAL] python-bleach vulnerabilities
python-bleach vulnerabilities
It was discovered that Bleach did not properly sanitize URI attributes
containing character entities. An attacker could possibly use this issue
to construct a URI with a disallowed scheme that would bypass
sanitization, leading to cross-site scripting. This issue only affected
Ubuntu 18.04 LTS. (CVE-2018-7753)
Yaniv Nizry discovered that Bleach was vulnerable to a mutation
cross-site scripting issue when sanitizing HTML with the noscript tag
and a raw tag in the allowed tags list. An attacker could possibly
use this issue to inject malicious content, leading to cross-site
scripting. This issue only affected Ubuntu 18.04 LTS. (CVE-2020-6802)
Yaniv Nizry discovered that Bleach was vulnerable to a mutation
cross-site scripting issue when sanitizing HTML with R
OSV
CVE-2021-23980: A mutation XSS affects users calling bleach
osv·2023-02-16·CVSS 6.1
CVE-2021-23980 [MEDIUM] CVE-2021-23980: A mutation XSS affects users calling bleach
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.
OSV
Cross-site scripting in Bleach
osv·2021-02-02·CVSS 6.1
CVE-2021-23980 [MEDIUM] Cross-site scripting in Bleach
Cross-site scripting in Bleach
### Impact
A [mutation XSS](https://cure53.de/fp170.pdf) 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`.
### Patches
Users are encouraged to upgrade to bleach v3.3.0 or greater.
Note: bleach v3.3.0 introduces a breaking change to escape HTML comments by default.
### Workarounds
* modify `bleach.clean` calls to at least one of:
* not allow the `style`, `title`, `noscript`, `script`, `textarea`, `noframes`, `iframe`, or `xmp` tag
* not all
OSV
CVE-2021-23980: In Mozilla Bleach before 3
osv·2021-02-02
CVE-2021-23980 CVE-2021-23980: In Mozilla Bleach before 3
In Mozilla Bleach before 3.3.0, a mutation XSS affects users calling bleach.clean with math or svg; p or br; and style, title, noscript, script, textarea, noframes, iframe, or xmp tags with strip_comments=False.
GHSA
Cross-site scripting in Bleach
ghsa·2021-02-02·CVSS 6.1
CVE-2021-23980 [MEDIUM] CWE-79 Cross-site scripting in Bleach
Cross-site scripting in Bleach
### Impact
A [mutation XSS](https://cure53.de/fp170.pdf) 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`.
### Patches
Users are encouraged to upgrade to bleach v3.3.0 or greater.
Note: bleach v3.3.0 introduces a breaking change to escape HTML comments by default.
### Workarounds
* modify `bleach.clean` calls to at least one of:
* not allow the `style`, `title`, `noscript`, `script`, `textarea`, `noframes`, `iframe`, or `xmp` tag
* not all
Ubuntu
Bleach vulnerabilities
vendor_ubuntu·2026-03-05·CVSS 9.8
CVE-2018-7753 [CRITICAL] Bleach vulnerabilities
Title: Bleach vulnerabilities
Summary: Several security issues were fixed in Bleach.
It was discovered that Bleach did not properly sanitize URI attributes
containing character entities. An attacker could possibly use this issue
to construct a URI with a disallowed scheme that would bypass
sanitization, leading to cross-site scripting. This issue only affected
Ubuntu 18.04 LTS. (CVE-2018-7753)
Yaniv Nizry discovered that Bleach was vulnerable to a mutation
cross-site scripting issue when sanitizing HTML with the noscript tag
and a raw tag in the allowed tags list. An attacker could possibly
use this issue to inject malicious content, leading to cross-site
scripting. This issue only affected Ubuntu 18.04 LTS. (CVE-2020-6802)
Yaniv Nizry discovered that Bleach was vulnerable to a mutatio
Microsoft
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 tag
vendor_msrc·2023-02-14·CVSS 6.1
CVE-2021-23980 [MEDIUM] CWE-79 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 tag
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.
FAQ: Is Azure Linux the only Microsoft product that includes this open-source library and is therefore potentially affected by this vulnerability?
One of the main benefits to our customers who choose to use the Azure Linux distro is the commitment to keep it up to date with the most recent and most secure versions of the open source libraries with which the distro is composed. Microsoft is committed to transparency in this work which is why we began pub
Red Hat
python-bleach: Mutation cross-site scripting in bleach.clean
vendor_redhat·2021-02-02·CVSS 6.1
CVE-2021-23980 [MEDIUM] CWE-79 python-bleach: Mutation cross-site scripting in bleach.clean
python-bleach: Mutation cross-site scripting in bleach.clean
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.
Debian
CVE-2021-23980: python-bleach - A mutation XSS affects users calling bleach.clean with all of: svg or math in th...
vendor_debian·2021·CVSS 6.1
CVE-2021-23980 [MEDIUM] CVE-2021-23980: python-bleach - A mutation XSS affects users calling bleach.clean with all of: svg or math in th...
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.
Scope: local
bookworm: resolved (fixed in 3.2.1-2.1)
bullseye: resolved (fixed in 3.2.1-2.1)
forky: resolved (fixed in 3.2.1-2.1)
sid: resolved (fixed in 3.2.1-2.1)
trixie: resolved (fixed in 3.2.1-2.1)
No detection rules found.
No public exploits indexed.
2023-02-16
Published