CVE-2023-36823
Ruby vulnerability analysis and mitigation

Overview

Sanitize, an allowlist-based HTML and CSS sanitizer, was found to contain a security vulnerability (CVE-2023-36823) affecting versions 3.0.0 through 6.0.1. The vulnerability was discovered and disclosed in July 2023, impacting systems using Sanitize with either the built-in "relaxed" config or custom configurations that allow style elements and CSS at-rules (GitHub Advisory).

Technical details

The vulnerability stems from insufficient neutralization of style element content, which could allow attackers to bypass HTML and CSS sanitization controls. When using Sanitize's relaxed configuration or custom configs that permit style elements and CSS at-rules, carefully crafted input could be used to inject arbitrary HTML and CSS through the sanitization process (GitHub Release).

Impact

If exploited, this vulnerability could result in cross-site scripting (XSS) attacks or other undesired behavior when malicious HTML and CSS are rendered in a browser. The impact is particularly significant for applications that rely on Sanitize for content sanitization and use either the built-in relaxed configuration or custom configurations allowing style elements (Debian LTS).

Mitigation and workarounds

The issue has been fixed in Sanitize version 6.0.2, which implements additional escaping of CSS in style element content. For users unable to upgrade, alternative mitigations include using a Sanitize config that doesn't allow style elements, using a config that doesn't allow CSS at-rules, or manually escaping the character sequence (GitHub Advisory).

Additional resources


SourceThis report was generated using AI

Related Ruby vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-4249-gjr8-jpq3HIGH8.7
  • RubyRuby
  • prosemirror_to_html
NoYesNov 13, 2025
CVE-2025-64501HIGH7.6
  • RubyRuby
  • prosemirror_to_html
NoYesNov 10, 2025
GHSA-vfpf-xmwh-8m65HIGH7.6
  • RubyRuby
  • prosemirror_to_html
NoYesNov 07, 2025
GHSA-52c5-vh7f-26fxHIGH7.6
  • RubyRuby
  • prosemirror_to_html
NoYesNov 06, 2025
CVE-2025-12790HIGH7.4
  • RubyRuby
  • mqtt
NoYesNov 06, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management