Live threats

All CVEs / rails

CVE-2026-128069rails-html-sanitizer

Cross-site scripting via race condition in rails-html-sanitizer

Medium 4.7 No auth needed

Priority
46
CVSS 3.1
4.7
EPSS
—
Auth required
No
Published
Nov 13, 2026
Updated
Nov 18, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-79, CWE-362
SSVC (CISA)
Exploitation: none · Automatable: no · Technical impact: partial
Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N

What happens

rails-html-sanitizer before version 1.7.2 reuses a PermitScrubber object without synchronization in multithreaded environments, allowing concurrent calls with different allowlists to interfere with each other. An attacker can cause a script or event-handler attribute to be retained in sanitized output, resulting in XSS when rendered.

AI-generated summary (Claude) based on NVD and CISA data. Not reviewed yet: check the details in the vendor advisory.

Show the original NVD text

rails-html-sanitizer is responsible for sanitizing HTML fragments in Rails applications. Before 1.7.2, the HTML4 and HTML5 variants of Rails::HTML::SafeListSanitizer reuse one Rails::HTML::PermitScrubber across calls and mutate its tags and attributes without synchronization. In a multithreaded process, concurrent sanitize calls using different tags: or attributes: options can interleave and cause one call to use the other call's allowlist. If a permissive call admits a script element or event-handler attribute, output expected to be sanitized under a stricter policy can retain it and cause cross-site scripting when rendered. Applications that are single-threaded, use one identical allowlist everywhere, or provide a separate scrubber: are not affected. This issue is fixed in version 1.7.2.

Source text, unmodified. NVD.

What to do

Patch available · fixed versions: 1.7.2

Update rails-html-sanitizer to version 1.7.2 or later.

Vendor advisory · github.com ↗

AI-generated from public data; not reviewed.

  1. Apply the vendor's security update for rails-html-sanitizer.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
RubyGems rails-html-sanitizer < 1.7.2 1.7.2 gem "rails-html-sanitizer", ">= 1.7.2"

Per OSV / GitHub Advisories (GHSA-h7wh-q2qr-458c). Check the version in your lockfile before upgrading.

Affected products

As reported by the CNA that published the CVE. NVD has not added CPEs with versions yet.

On social media

1 person and 1 post on Bluesky in the last 30 days.

Most recent posts, without bots or automated feeds. The text belongs to its authors. Search on Bluesky

Official sources

References

Links published by the sources. Open them with care.