CVE-2026-54498: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in ViewComponent view_component
A cross-site scripting (XSS) vulnerability exists in the view_component Ruby on Rails framework versions from 4.0.0 up to but not including 4.12.0. The issue arises because ViewComponent::Base#around_render can return HTML-unsafe strings that bypass normal escaping, and ViewComponent::Collection#render_in can mark combined output as safe, potentially exposing user-controlled data. This vulnerability is fixed in version 4.12.0.
AI Analysis
Technical Summary
The view_component framework for Ruby on Rails versions >=4.0.0 and <4.12.0 contains an XSS vulnerability due to improper neutralization of input during web page generation (CWE-79). Specifically, ViewComponent::Base#around_render may return HTML-unsafe strings that bypass escaping, and ViewComponent::Collection#render_in can amplify this by joining per-item results and marking the entire output as html_safe, converting unsafe raw output into an ActiveSupport::SafeBuffer. This can lead to cross-site scripting when user-controlled data is included in the around_render output. The vulnerability is resolved in version 4.12.0.
Potential Impact
Successful exploitation can lead to cross-site scripting attacks, allowing an attacker to execute arbitrary scripts in the context of the vulnerable application. This can result in compromise of user sessions, defacement, or redirection to malicious sites. The CVSS v3.1 score is 8.7 (high), indicating a significant risk with network attack vector, low attack complexity, requiring low privileges and user interaction, with impact on confidentiality and integrity but not availability.
Mitigation Recommendations
Upgrade to view_component version 4.12.0 or later, where this vulnerability is fixed. No other mitigations are specified. Patch status is confirmed fixed in 4.12.0.
CVE-2026-54498: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in ViewComponent view_component
Description
A cross-site scripting (XSS) vulnerability exists in the view_component Ruby on Rails framework versions from 4.0.0 up to but not including 4.12.0. The issue arises because ViewComponent::Base#around_render can return HTML-unsafe strings that bypass normal escaping, and ViewComponent::Collection#render_in can mark combined output as safe, potentially exposing user-controlled data. This vulnerability is fixed in version 4.12.0.
CVSS v3.1
Score 8.7high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The view_component framework for Ruby on Rails versions >=4.0.0 and <4.12.0 contains an XSS vulnerability due to improper neutralization of input during web page generation (CWE-79). Specifically, ViewComponent::Base#around_render may return HTML-unsafe strings that bypass escaping, and ViewComponent::Collection#render_in can amplify this by joining per-item results and marking the entire output as html_safe, converting unsafe raw output into an ActiveSupport::SafeBuffer. This can lead to cross-site scripting when user-controlled data is included in the around_render output. The vulnerability is resolved in version 4.12.0.
Potential Impact
Successful exploitation can lead to cross-site scripting attacks, allowing an attacker to execute arbitrary scripts in the context of the vulnerable application. This can result in compromise of user sessions, defacement, or redirection to malicious sites. The CVSS v3.1 score is 8.7 (high), indicating a significant risk with network attack vector, low attack complexity, requiring low privileges and user interaction, with impact on confidentiality and integrity but not availability.
Mitigation Recommendations
Upgrade to view_component version 4.12.0 or later, where this vulnerability is fixed. No other mitigations are specified. Patch status is confirmed fixed in 4.12.0.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-97jw-64cj-jc58
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2026-54498"]
- Ecosystems
- ["RubyGems"]
- Database Specific Severity
- HIGH
- Cvss Version
- 3.1
Threat ID: 6a58b40468715ace43d67071
Added to database: 07/16/2026, 10:35:48 UTC
Last enriched: 07/23/2026, 21:00:23 UTC
Last updated: 09/01/2026, 17:58:32 UTC
Views: 121
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.