| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| prosemirror_to_html | rubygems | < 0.2.1 | 0.2.1 |
The vulnerability lies in the prosemirror_to_html gem, specifically within the Renderer.render_opening_tag function located in lib/prosemirror_to_html.rb. The analysis of the patch in commit 4d59f94f550bcabeec30d298791bbdd883298ad8 reveals that HTML attribute values were being directly concatenated into the output string without proper sanitization. The vulnerable line, attrs << " #{attr}=\"#{value}\"", was replaced with code that utilizes CGI.escapeHTML to neutralize potentially malicious content in attribute values. This absence of escaping created a Cross-Site Scripting (XSS) vulnerability, as it allowed attackers to inject malicious payloads, such as javascript: URLs or on* event handlers, into the rendered HTML.
Renderer.render_opening_taglib/prosemirror_to_html.rb
Ongoing coverage of React2Shell