What’s Vulnerable › Vulnerabilities
CVE-2023-23913: rails-ujs vulnerable to DOM Based Cross-site Scripting contenteditable HTML Elements
- Severity: medium (CVSS 6.3 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.6% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2025-01-09 · updated 2026-06-17
- Weakness: CWE-79
Description
There is a potential DOM based cross-site scripting issue in rails-ujs which leverages the Clipboard API to target HTML elements that are assigned the contenteditable attribute. This has the potential to occur when pasting malicious HTML content from the clipboard that includes a data-method, data-remote or data-disable-with attribute.
Affected products
- Rubygems Actionview: from 5.1.0 before 6.1.7.3; from 7.0.0 before 7.0.4.3; 5.1.0, 5.1.1, 5.1.2, 5.1.2.rc1, 5.1.3, 5.1.3.rc1 (+112) — fixed in 6.1.7.3, 7.0.4.3
- rails-ujs: from 6.1.7.3 before 6.1.7.3; from 7.0.4.3 before 7.0.4.3 — fixed in 6.1.7.3, 7.0.4.3
How to fix
Upgrade to a fixed version: Rubygems Actionview 6.1.7.3, 7.0.4.3; rails-ujs 6.1.7.3, 7.0.4.3. Check the vendor advisory for mitigations.
References
- https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1033263
- https://discuss.rubyonrails.org/t/cve-2023-23913-dom-based-cross-site-scripting-in-rails-ujs-for-contenteditable-html-elements/82468
- https://github.com/rails/rails/commit/5037a13614d71727af8a175063bcf6ba1a74bdbd
- https://security.netapp.com/advisory/ntap-20240605-0007/
- https://www.debian.org/security/2023/dsa-5389
Get alerted when CVE-2023-23913 or the next vulnerability affects your stack