CVE-2026-128068
rails-html-sanitizer is responsible for sanitizing HTML fragments in R ...
Overview
Description
rails-html-sanitizer is responsible for sanitizing HTML fragments in Rails applications. From 1.0.3 through 1.7.1, Rails::HTML::PermitScrubber checks SVG href and xlink:href local references with a pattern whose line-start anchor and whitespace class cause an all-whitespace value to be rescanned from each line start. An attacker who supplies HTML can cause quadratic CPU consumption when an application customizes its allowed tags to include an SVG reference element such as use and permits href or xlink:href. The default allowed tag configuration is not affected. CRuby 3.2 and later uses linear-time regular expression matching for this pattern, while CRuby 3.1 and earlier and JRuby are affected. This issue is fixed in version 1.7.2.
Source: OX vulnerability database
Severity
5.3 · MEDIUM
CVSS 3.1 base score, scored by NVD.
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- None
- Integrity
- None
- Availability
- Low
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Weakness: CWE-400, CWE-1333
Affected packages · 1
| Ecosystem | Package | Vulnerable | Fixed in |
|---|---|---|---|
| RubyGems | rails-html-sanitizer | >=1.0.3, <1.7.2 | 1.7.2 |
Open a package to see all its vulnerabilities.
Operating systems · 5 fixes
debian 4 releases · 1 package
| Release | Package | Fixed in |
|---|---|---|
| 11 | ruby-rails-html-sanitizer | affected |
| 12 | ruby-rails-html-sanitizer | affected |
| 13 | ruby-rails-html-sanitizer | affected |
| 14 | ruby-rails-html-sanitizer | affected |
echo 1 release · 1 package
| Release | Package | Fixed in |
|---|---|---|
| ruby-rails-html-sanitizer | affected |
References
- github.com https://github.com/rails/rails-html-sanitizer
- github.com https://github.com/rails/rails-html-sanitizer/commit/f776f963b9d9346271aade9cb903e793fd38e865
- github.com https://github.com/rails/rails-html-sanitizer/releases/tag/v1.7.2
- github.com https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-cpgf-5mjf-73p7
- github.com https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rails-html-sanitizer/GHSA-cpgf-5mjf-73p7.yml
OX Radar and Response Center
Find threats in your stack.
OX Radar can check high-priority threats, like critical package CVEs, against your context.
Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.