XSS in Rails Rails-Html-Sanitizer
CVE-2018-3741
There is a possible XSS vulnerability in all rails-html-sanitizer gem versions below 1.0.4 for Ruby. The gem allows non-whitelisted attributes to be present in sanitized output when input with specially-crafted HTML fragments, and these attributes can lead to an XSS attack on target applications. This issue is similar to CVE-2018-8048 in Loofah. All users running an affected release should either upgrade or use one of the workarounds immediately.
Vulnerability class: XSS (Cross-Site Scripting)
Published · last modified .
CVSS v3 metric
CVSS v3 base score 6.1 (Medium). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N.
EPSS exploit prediction
EPSS 0.013, 69.9th percentile (scored ); unchanged over 30 days. About EPSS.
Affected products
- Rails Rails-Html-Sanitizer — versions <= 1.0.3
- Rubyonrails HTML Sanitizer
Weakness classification (CWE)
Public exploits and proof-of-concept code
Also mentioned in 7 other repositories (KorayAgaya/TrivyWeb, Mohzeela/external-secret, Shreda/todoappnotes, …). These reference the CVE in a list, notes or a scanner and are not exploit code for it.
References
- github.com/rails/rails-html-sanitizer/commit/f3ba1a839a35f2ba7f941c15e239a1cb37… (Patch, Third Party Advisory, Issue Tracking)