Skip to content
OpenAdvisories
Medium · 5.1 CVE-2026-73648 EUVD-2026-58191GHSA-cj75-f6xr-r4g7

rails-html-sanitizer: Possible XSS vulnerability with certain configurations

Published Aug 13, 2026 · Updated Aug 13, 2026 · Assigned by GitHub_M

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.

Affected products

VendorProductAffectedFixed
rails rails-html-sanitizer >= 1.0.3, < 1.7.1 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 ruby-rails-html-sanitizer 1.7.1-1 —
Debian 13 ruby-rails-html-sanitizer No fix yet —
Debian 12 ruby-rails-html-sanitizer No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 26.04 LTS ruby-rails-html-sanitizer No fix yet —
Ubuntu 24.04 LTS ruby-rails-html-sanitizer No fix yet —
Ubuntu 22.04 LTS ruby-rails-html-sanitizer No fix yet —
Ubuntu 20.04 LTS ruby-rails-html-sanitizer No fix yet —
Ubuntu 18.04 LTS ruby-rails-html-sanitizer No fix yet —
Show 1 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu 16.04 LTS ruby-rails-html-sanitizer No fix yet —
ReleasePackageFixed inAdvisory
SLES 15 SP7 rubygem-rails-html-sanitizer 1.0.4-150000.4.9.1 SUSE-SU-2026:4445-1
SLES 15 SP6 rubygem-rails-html-sanitizer 1.0.4-150000.4.9.1 SUSE-SU-2026:4445-1
SLES 15 SP5 rubygem-rails-html-sanitizer 1.0.4-150000.4.9.1 SUSE-SU-2026:4445-1
SLES 15 SP4 rubygem-rails-html-sanitizer 1.0.4-150000.4.9.1 SUSE-SU-2026:4445-1
Show 2 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES for SAP 16.0 hawk2 2.7.2+git.1788518533.7d4dadd6-160000.1.1 SUSE-SU-2026:24250-1
SLES 16.0 hawk2 2.7.2+git.1788518533.7d4dadd6-160000.1.1 SUSE-SU-2026:24195-1
ReleasePackageFixed inAdvisory
openSUSE Tumbleweed hawk2 2.7.2+git.1792148770.648dcddb-1.1 openSUSE-SU-2026:12153-1
openSUSE Leap 16.0 hawk2 2.7.2+git.1788518533.7d4dadd6-160000.1.1 openSUSE-SU-2026:22068-1

Wolfi

ReleasePackageFixed inAdvisory
Wolfi rolling ruby3.2-rails-8.1 8.1.3-r9 —
Wolfi rolling ruby3.4-rails-8.1 8.1.3-r11 —
Wolfi rolling ruby4.0-rails-8.1 8.1.3-r10 —

Affected packages

EcosystemPackageAffectedFixedRecord
RubyGems rails-html-sanitizer >= 1.0.3, < 1.7.1 1.7.1 GHSA-cj75-f6xr-r4g7

Advisories 5

References