CVE & CISA-KEV Catalog

CVE-2022-23520

MEDIUM
6.1
CVSS v3
NVD

Description

rails-html-sanitizer is responsible for sanitizing HTML fragments in Rails applications. Prior to version 1.4.4, there is a possible XSS vulnerability with certain configurations of Rails::Html::Sanitizer due to an incomplete fix of CVE-2022-32209. Rails::Html::Sanitizer may allow an attacker to inject content if the application developer has overridden the sanitizer's allowed tags to allow both "select" and "style" elements. Code is only impacted if allowed tags are being overridden. This issue is patched in version 1.4.4. All users overriding the allowed tags to include both "select" and "style" should either upgrade or use this workaround: Remove either "select" or "style" from the overridden allowed tags. NOTE: Code is _not_ impacted if allowed tags are overridden using either the :tags option to the Action View helper method sanitize or the :tags option to the instance method SafeListSanitizer#sanitize.

How to fix

Remediation Available
ruby-rails-html-sanitizerDebian
Fixed in:1.3.0-1+deb11u1CVE-2022-23520
Fixed in:1.4.4-1CVE-2022-23520
Fixed in:1.4.4-1CVE-2022-23520
Fixed in:1.4.4-1CVE-2022-23520

Remediation is compiled from vendor and distribution security advisories. Always confirm against the linked source for your exact version and platform.

CVSS v3 Vector

Exploitability

Attack VectorNetwork
Attack ComplexityLow
Privileges RequiredNone
User InteractionRequired
ScopeChanged

Impact

ConfidentialityLow
IntegrityLow
AvailabilityNone

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

Exploit Intelligence

1.11%probability of exploitation in 30 days
62ndpercentile

Moderate risk: more likely to be exploited than 62% of all known CVEs.

References

Third-Party Advisory1
Other references1

Related Vulnerabilities

Other CWE-79 (Cross-Site Scripting (XSS)) vulnerabilities, ordered by exploit likelihood. View all

CVESeverityCVSSEPSSExploitedFix
CVE-2020-11022Medium6.999%-Fix
CVE-2019-3929Critical9.899%KEVFix
CVE-2020-9496Medium6.199%--
CVE-2023-28341Medium6.199%-Fix
CVE-2018-12998Medium6.198%--
CVE-2025-4123High7.698%-Fix
Embed a live status badge for CVE-2022-23520
CVE-2022-23520 severity badge

Markdown

[![CVE-2022-23520](https://tridentstack.com/cve/badge/CVE-2022-23520.svg)](https://tridentstack.com/cve/CVE-2022-23520)

HTML

<a href="https://tridentstack.com/cve/CVE-2022-23520"><img src="https://tridentstack.com/cve/badge/CVE-2022-23520.svg" alt="CVE-2022-23520"></a>

Find and fix vulnerabilities across your fleet

TridentStack Control continuously scans your Windows, macOS, and Linux fleet for known vulnerabilities, prioritizes them by severity and active exploitation, and patches them automatically.

Start free

This product uses NVD data but is not endorsed or certified by the NVD. EPSS scores courtesy of FIRST.org (https://www.first.org/epss). Source: CISA KEV Catalog. Data as of 2025-11-03.