CVE-2021-23648 Cross-site Scripting (XSS)
An attacker can execute arbitrary scripts via improper URL sanitization in the @braintree/sanitize-url library, affecting applications using this package.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2021-23648?
CVE-2021-23648 is a medium-severity cross-site scripting vulnerability in Fedoraproject Fedora, published on 16 Mar 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
The package @braintree/sanitize-url before 6.0.0 are vulnerable to Cross-site Scripting (XSS) due to improper sanitization in sanitizeUrl function.
Weakness: CWE-79
Which versions are affected by CVE-2021-23648?
2 open source packages ship an affected version, including @braintree/sanitize-url. It affects 2 products.
| Package | Affected | Fixed in |
|---|---|---|
@braintree/sanitize-url npm | All versions | 6.0.0 |
@braintree/sanitize-url npm | All versions | 6.0.0 |
Products include Fedoraproject Fedora, Paypal Braintree\/Sanitize-Url.
How do I fix CVE-2021-23648?
Upgrade @braintree/sanitize-url to 6.0.0 or later.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2021-23648 being exploited?
There is no known exploitation of CVE-2021-23648 in the wild and no public exploit code.
Other vulnerabilities in Fedoraproject Fedora
Sources
Also known as DEBIAN-CVE-2021-23648, GHSA-hqq7-2q2v-82xq, SNYK-JS-BRAINTREESANITIZEURL-2339882, UBUNTU-CVE-2021-23648.