Skip to content
Threat Brief

← All advisories

CVE-2026-126079

Medium 6.1No known exploitationFix available

Action View: Possible XSS vulnerability in Action View text helpers

Vendor advisory: GHSA-2p2f-4rq4-gjwc

Record last updated

CVSS score

6.1

Medium on a 0 to 10 scale

EPSS, chance of exploitation in 30 days

None

No EPSS score available

CISA remediation deadline

None

Not in the KEV catalog

Description

### Impact With the HTML5 sanitizer (`Rails::HTML5::Sanitizer`, the default vendor on CRuby for applications using `load_defaults 7.1` or later), Nokogiri before 1.19.5 serializes ` ` unescaped inside attribute values. The Action View text helpers `highlight` and `simple_format` sanitize their input and then process the resulting HTML as a string: `highlight` splits it on tag boundaries to insert matches, and `simple_format` splits it into paragraphs on blank lines. An unescaped `>` or a blank line inside an attribute value could cause markup in that value, which the sanitizer left inert, to be emitted as live elements in the helper's `html_safe` output, possibly leading to XSS. Applications that use the HTML5 sanitizer and pass untrusted text to `highlight`, or to `simple_format` with `html_options`, are affected. ### Details The fixed releases require rails-html-sanitizer 1.7.2 or later, which requires Loofah 2.25.3 and Nokogiri 1.19.5. With these versions, the HTML5 sanitizer escapes ` ` in attribute values as `<` and `>`, as the HTML4 sanitizer already does. The parsed DOM is unchanged, but code or tests that compare sanitized HTML as a string may see the new serialization. ##…

Weakness: CWE-79

Patching and mitigation

Patch status
Fix available (source: Microsoft MSRC)
Fix documented (source date)
Mitigation
None documented
Vendor guidance
msrc.microsoft.com (opens in a new tab)

Affected products

VendorProductAffected versionsFixed inPer
Microsoftazl4 rubygem-actionview 8.0.2-5.azl4 on Azure Linux 4.0Not documentedNot documentedMicrosoft MSRC
rubygemsactionviewfrom 8.1.0.beta1 before 8.1.4.18.1.4.1GitHub Advisory Database
rubygemsactionviewall versions before 8.0.5.28.0.5.2GitHub Advisory Database

Timeline

  1. Advisory

    Microsoft advisory published

    Source: Microsoft MSRC (opens in a new tab)

  2. Patch

    Fix documented by Microsoft MSRC

    Source: Microsoft MSRC (opens in a new tab)

Vendor guidance and references