CVE-2026-73648
rails-html-sanitizer: rails-html-sanitizer: Cross-Site Scripting vulnerability due to improper SVG sanitization
Overview
Description
rails-html-sanitizer is responsible for sanitizing HTML fragments in Rails applications. From 1.0.3 until 1.7.1, Rails::HTML::PermitScrubber restricted SVG reference elements in SVG_ALLOW_LOCAL_HREF only when they used xlink:href, even though browsers also accept the plain href attribute. Applications with non-default allowed tags that included SVG use or feImage elements could therefore permit external references; a same-origin external SVG referenced by use could execute scripts in the sanitized document's context, while feImage could load external images for tracking. Applications using the default allowed tags are not affected. This issue is fixed in version 1.7.1.
Source: OX vulnerability database
Severity
5.4 · MEDIUM
CVSS 3.1 base score, scored by redhat.
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- Required
- Scope
- Unchanged
- Confidentiality
- Low
- Integrity
- Low
- Availability
- None
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
Weakness: CWE-79
Affected packages · 1
| Ecosystem | Package | Vulnerable | Fixed in |
|---|---|---|---|
| RubyGems | rails-html-sanitizer | >=1.0.3, <1.7.1 | 1.7.1 |
Open a package to see all its vulnerabilities.
Operating systems · 35 fixes
Red Hat 2 releases · 1 package
| Release | Package | Fixed in |
|---|---|---|
| 7 | rubygem-rails-html-sanitizer | affected |
| 7 (satellite:el8) | rubygem-rails-html-sanitizer | affected |
SUSE Linux Enterprise 6 releases · 4 packages
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| 15.4 | ruby2-5-rubygem-rails-html-sanitizer | 1.0.4-150000.4.9.1 | SUSE-SU-2026:4445-1 |
| 15.5 | ruby2-5-rubygem-rails-html-sanitizer | 1.0.4-150000.4.9.1 | SUSE-SU-2026:4445-1 |
| 15.6 | ruby2-5-rubygem-rails-html-sanitizer | 1.0.4-150000.4.9.1 | SUSE-SU-2026:4445-1 |
| 15.7 | ruby2-5-rubygem-rails-html-sanitizer | 1.0.4-150000.4.9.1 | SUSE-SU-2026:4445-1 |
| 16.0 | hawk2 | 2.7.2+git.1788518533.7d4dadd6-160000.1.1 | SUSE-SU-2026:24195-1 |
| 16.1 | hawk-apiserver | 0.2.4+git.1792406875.6ed758a-160100.1.1 | SUSE-SU-2026:24712-1 |
2 more rows
chainguard 1 release · 13 packages
| Release | Package | Fixed in |
|---|---|---|
| commercial-gitlab-rails-ee-19-2 +1 | 19.2.7-r4 | |
| gitlab-rails-ce-fips-19-3 | 19.3.1-r3 | |
| gitlab-rails-ce-19-3 | 19.3.1-r6 | |
| pghero | 3.8.0-r5 | |
| pghero-fips | 3.8.0-r6 | |
| ruby3-4-rails-7-2 | 7.2.3.1-r10 |
7 more rows
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 | 1.7.1-1 |
echo 1 release · 1 package
| Release | Package | Fixed in |
|---|---|---|
| ruby-rails-html-sanitizer | affected |
openSUSE 1 release · 1 package
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Tumbleweed | hawk2 | 2.7.2+git.1792148770.648dcddb-1.1 | openSUSE-SU-2026:12153-1 |
openSUSE Leap 2 releases · 2 packages
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| 16.0 | hawk2 | 2.7.2+git.1788518533.7d4dadd6-160000.1.1 | openSUSE-SU-2026:22068-1 |
| 16.1 | hawk-apiserver | 0.2.4+git.1792406875.6ed758a-160100.1.1 | openSUSE-SU-2026:22305-1 |
| 16.1 | hawk2 | 2.7.2+git.1789128469.a738abc1-160100.1.1 | openSUSE-SU-2026:22305-1 |
wolfi 1 release · 3 packages
| Release | Package | Fixed in |
|---|---|---|
| ruby4-0-rails-8-1 | 8.1.3-r10 | |
| ruby3-4-rails-8-1 | 8.1.3-r11 | |
| ruby3-2-rails-8-1 | 8.1.3-r9 |
References
- access.redhat.com https://access.redhat.com/security/cve/CVE-2026-73648
- discuss.rubyonrails.org https://discuss.rubyonrails.org/t/ghsa-cj75-f6xr-r4g7-possible-xss-vulnerability-with-certain-configurations-of-rails-html-sanitizer/91359#post_1
- github.com https://github.com/advisories/GHSA-cj75-f6xr-r4g7
- github.com https://github.com/flavorjones/loofah/security/advisories/GHSA-9wjq-cp2p-hrgf
- github.com https://github.com/rails/rails-html-sanitizer
- github.com https://github.com/rails/rails-html-sanitizer/blob/main/CHANGELOG.md#v171--2026-07-15
- github.com https://github.com/rails/rails-html-sanitizer/commit/74dcb8053e6da9921246ce71b06ad9fd65b19586
- github.com https://github.com/rails/rails-html-sanitizer/pull/223
- github.com https://github.com/rails/rails-html-sanitizer/releases/tag/v1.7.1
- github.com https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-cj75-f6xr-r4g7
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.