CVE-2023-36823

Source
https://nvd.nist.gov/vuln/detail/CVE-2023-36823
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2023-36823.json
Aliases
Related
Published
2023-07-06T16:15:10Z
Modified
2023-12-22T17:02:05.880524Z
Details

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.

References

Affected packages

Git / github.com/rgrove/sanitize

Affected ranges

Type
GIT
Repo
https://github.com/rgrove/sanitize
Events

Affected versions

v3.*

v3.0.0
v3.0.1
v3.0.2
v3.0.3
v3.0.4
v3.1.0
v3.1.1
v3.1.2

v4.*

v4.0.0
v4.0.1
v4.1.0
v4.2.0
v4.3.0
v4.4.0
v4.5.0
v4.6.0
v4.6.1
v4.6.2
v4.6.3
v4.6.4
v4.6.5
v4.6.6

v5.*

v5.0.0
v5.1.0
v5.2.0
v5.2.1
v5.2.2
v5.2.3

v6.*

v6.0.0
v6.0.1