CVE-2026-33170

Rails Active Support has a possible XSS vulnerability in SafeBuffer#%

MEDIUM
6.1
CVSS Score
Published: March 23, 2026 at 11:09 PM UTC
Updated: June 17, 2026 at 10:37 AM UTC
2 products affected across 2 vendorsRailsActive Support

Using rails by rails?

Get instant alerts when new vulnerabilities affect rails - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM6.1
Exploit prediction
EPSS 0.3%
SSVC
No known exploit

Description

Active Support is a toolkit of support libraries and Ruby core extensions extracted from the Rails framework. Prior to versions 8.1.2.1, 8.0.4.1, and 7.2.3.1, `SafeBuffer#%` does not propagate the `@html_unsafe` flag to the newly created buffer. If a `SafeBuffer` is mutated in place (e.g. via `gsub!`) and then formatted with `%` using untrusted arguments, the result incorrectly reports `html_safe? == true`, bypassing ERB auto-escaping and possibly leading to XSS. Versions 8.1.2.1, 8.0.4.1, and 7.2.3.1 contain a patch.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v < 7.2.3.18.0.0 ≤ v < 8.0.4.18.1.0 ≤ v < 8.1.2.1
v < 7.2.3.1v < 8.0.4.1v < 8.1.2.1
Affected range stops below 7.2.3.1, so it looks safe — our inference, not a vendor statement
Affected range stops below 8.0.4.1, so it looks safe — our inference, not a vendor statement
Affected range stops below 8.1.2.1, so it looks safe — our inference, not a vendor statement

References (7)

SSVC — Action Prioritization

SSVCNo known exploitNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

Attack Vector
NETWORK
Complexity
LOW
Privileges
NONE
User Interaction
REQUIRED
Scope
CHANGED
Confidentiality
LOW
Integrity
LOW
Availability
NONE
Vector?

Quick Info

StatusANALYZED
CWE
CWE-79

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card