CVE-2023-36823 Sanitize vulnerable to Cross-site Scripting via insufficient neutralization of `style` element content

High 7.1 Published Updated
Exploited in the wild
Not known
Fix
Available

What is CVE-2023-36823?

CVE-2023-36823 is a high-severity vulnerability in Debian Debian Linux, published on 6 Jul 2023.

Official description

Sanitize is an allowlist-based HTML and CSS sanitizer. Using carefully crafted input, an attacker may be able to sneak arbitrary HTML and CSS through Sanitize starting with version 3.0.0 and prior to version 6.0.2 when Sanitize is configured to use the built-in "relaxed" config or when using a custom config that allows `style` elements and one or more CSS at-rules. This could result in cross-site scripting or other undesired behavior when the malicious HTML and CSS are rendered in a browser. Sanitize 6.0.2 performs additional escaping of CSS in `style` element content, which fixes this issue. Users who are unable to upgrade can prevent this issue by using a Sanitize config that doesn't allow `style` elements, using a Sanitize config that doesn't allow CSS at-rules, or by manually escaping the character sequence `</` as `<\/` in `style` element content.

Weakness: CWE-79

Which versions are affected by CVE-2023-36823?

2 open source packages ship an affected version, including sanitize. It affects 2 products.

PackageAffectedFixed in
sanitize RubyGemsFrom 3.0.06.0.2
sanitize RubyGemsFrom 3.0.06.0.2

Products include Debian Debian Linux, Sanitize Project Sanitize.

How do I fix CVE-2023-36823?

Upgrade sanitize to 6.0.2 or later.

Is CVE-2023-36823 being exploited?

There is no known exploitation of CVE-2023-36823 in the wild and no public exploit code.

All Debian Debian Linux vulnerabilities

Sources

Also known as DEBIAN-CVE-2023-36823, DLA-3652-1, DSA-5616-1, GHSA-f5ww-cq3m-q3g7, UBUNTU-CVE-2023-36823.

Is CVE-2023-36823 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free