CVE-2026-126203

Description

Loofah is a general library for manipulating and transforming HTML/XML documents and fragments, built on top of Nokogiri. From 2.21.0 until 2.25.3, Loofah's HTML5 APIs Loofah.html5_fragment, Loofah.html5_document, and the scrub_html5_* methods can emit sanitized output that a browser reparses as different markup when used with Nokogiri before 1.19.5, because those Nokogiri versions do not escape angle brackets in attribute values. MathML can place markup inside an allowed attribute so the reparsed output becomes live HTML. The :strip scrubber is affected in every browser, while :prune and :escape are affected in WebKit browsers. Loofah's HTML4 APIs, Loofah::Helpers.sanitize, :whitewash, rails-html-sanitizer's default configuration, and JRuby are not affected. This issue is fixed in version 2.25.3.

Severity
MEDIUM
CVSS v3
6.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N · source cna
Exploit chance (EPSS)
0.271%
chance of exploitation in the next 30 days
higher than 19.6% of scored CVEs · 2026-11-18
CISA KEV
Not listed
Public exploit code
None public
Exploit references (NVD and CNA): 0
Metasploit modules: 0
Nuclei templates: 0

Weakness

CISA SSVC decision points

Exploitationnone
Automatableno
Technical impactpartial
Scored2026-11-12

Timeline

  1. 2026-11-12Published by the CNA18:06 UTC
  2. 2026-11-12GitHub advisory published (GHSA-h6v6-rg66-fqj4)same day
  3. 2026-11-12CISA SSVC decision recordedsame day

The timeline shows what already happened. To be told when this CVE changes next, watch it from the API.

Exploit and advisory records

GitHub advisory GHSA-h6v6-rg66-fqj4, affected packages:

PackageVulnerable versionsFixed in
RubyGems loofahfrom 2.21.0 before 2.25.32.25.3

Affected products

Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.

ProductVulnerable versionsFixed in
flavorjones loofah

Products and versions as NVD and the vendor that published the CVE list them.

References

Get more CVE data from the API.

Free without a key or signup. Pro adds monitoring and higher limits: pricing.

Sources