CVE-2026-126078

Action View: Possible XSS vulnerability in Action View highlight helper

Published Nov 10, 2026 CVSS 3.1 · 6.1 Medium EPSS < 1% KEV · Not listed
Description
Action View is a framework for handling view template lookup and rendering and provides view helpers for building HTML. Prior to 8.1.4.1 and 8.0.5.2, ActionView::Helpers::TextHelper#highlight substitutes each matched phrase into the :highlighter string without escaping it and returns the result marked HTML-safe. Because sanitizing leaves quote characters in text unescaped, a match substituted into a quoted attribute value of the highlighter, such as the <a href="search?q=\1"> form shown in the method's documentation, could end the attribute value and add attributes to the element, possibly leading to XSS. Applications are affected when they pass a :highlighter that places a placeholder inside an attribute value and highlight text or phrases that a user controls. The default <mark>\1</mark> highlighter and the block form are not affected. This issue is fixed in versions 8.1.4.1 and 8.0.5.2.

Analysis

AI-generated

Technical impact

Action View's highlight helper substitutes each matched phrase into a supplied highlighter string without escaping any characters. When a user‑controlled string is highlighted and the highlighter places a placeholder within an attribute value, an attacker can terminate the attribute and inject arbitrary HTML or JavaScript, resulting in reflected cross‑site scripting. The vulnerability does not require elevated privileges and operates with user input that reaches the highlight method; the CVSS score of 6.1 indicates moderate severity.

Affected Systems

Ruby on Rails applications running Rails versions earlier than 8.1.4.1 or 8.0.5.2 are affected. The flaw exists in the ActionView::Helpers::TextHelper#highlight method. Any Rails project that calls this helper with a custom highlighter containing an attribute placeholder and highlights content derived from user input is susceptible.

Risk and Exploitability

The CVSS score of 6.1 reflects moderate impact. The EPSS score is below 1 %, suggesting low likelihood of exploitation in the wild. The vulnerability is not cataloged in CISA's KEV list. Attackers can achieve reflected XSS through the custom highlighter mechanism, potentially tricking users into executing malicious scripts in their browsers. The attack requires only a malformed request containing user‑controlled text and a vulnerable highlighter string.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Rails to 8.1.4.1, 8.0.5.2, or a later release that includes the fix.
  • If upgrading is not immediately feasible, configure the highlight helper to use the default "<mark>\\1</mark>" highlighter or the block form, which do not place placeholders within attribute values.
  • Always sanitize or escape any user‑controlled content before passing it to the highlight helper or rendering it in attribute contexts to prevent unintended injection.

Generated by OpenCVE AI on November 13, 2026 at 15:08 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Debian DLA Debian DLA DLA-4934-1 rails security update
Github GHSA Github GHSA GHSA-v6rj-xm57-3p59 Action View: Possible XSS vulnerability in highlight helper
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Rails
Rails rails
Vendors & Products Rails
Rails rails
Type Values Removed Values Added
Description Action View is a framework for handling view template lookup and rendering and provides view helpers for building HTML. Prior to 8.1.4.1 and 8.0.5.2, ActionView::Helpers::TextHelper#highlight substitutes each matched phrase into the :highlighter string without escaping it and returns the result marked HTML-safe. Because sanitizing leaves quote characters in text unescaped, a match substituted into a quoted attribute value of the highlighter, such as the <a href="search?q=\1"> form shown in the method's documentation, could end the attribute value and add attributes to the element, possibly leading to XSS. Applications are affected when they pass a :highlighter that places a placeholder inside an attribute value and highlight text or phrases that a user controls. The default <mark>\1</mark> highlighter and the block form are not affected. This issue is fixed in versions 8.1.4.1 and 8.0.5.2.
Title Action View: Possible XSS vulnerability in Action View highlight helper
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 6.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N'}

Weaknesses
  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Nov 12, 2026, 6:01 PM
Reserved
Nov 10, 2026, 5:07 PM
Status
Awaiting Analysis
Published
Nov 10, 2026, 9:19 PM
Modified
Nov 12, 2026, 10:09 PM