CVE-2011-2197 rubyonrails: Cross-site Scripting
rubyonrails: no CVSS score yet. EPSS 2.0% estimated probability of exploitation activity in the next 30 days. Fixed in actionpack 2.3.12, 3.0.8.
On this page
The cross-site scripting (XSS) prevention feature in Ruby on Rails 2.x before 2.3.12, 3.0.x before 3.0.8, and 3.1.x before 3.1.0.rc2 does not properly handle mutation of safe buffers, which makes it easier for remote attackers to conduct XSS attacks via crafted strings to an application that uses a problematic string method, as demonstrated by the sub method.
- EPSS
- 2.0% (unchanged from 2.0% a week ago; 2.0% 30 days ago) estimated probability of exploitation activity in the next 30 days; 81st percentile. Scored 2026-11-21. A forecast for this CVE across the internet, not for your own systems.
- CWE
- CWE-79 Improper Neutralization of Input During Web Page Generation (Cross-site Scripting)
- OWASP Top 10
- A05:2025 Injection
- Published
- Modified
- NVD analysis
- Analyzed, since modified
- Record from
- the NVD, synced
Fix and patched versions
actionpack(RubyGems): fixed in 2.3.12, 3.0.8activesupport(RubyGems): fixed in 2.3.12, 3.0.8- Patch: http://groups.google.com/group/rubyonrails-security/msg/663b600d4471e0d4?dmode=source&output=gplain
- Patch: http://openwall.com/lists/oss-security/2011/06/09/2
- Patch: http://openwall.com/lists/oss-security/2011/06/13/9
- Vendor advisory: http://secunia.com/advisories/44789
Ask an AI about this CVE
Show the prompt
Explain CVE-2011-2197 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2011-2197?via=ask-ai-copy and https://cve.bz/cve/CVE-2011-2197?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2011-2197 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.
Affected
Versions
From the NVD's CPE matches.
| Product | Affected |
|---|---|
| rubyonrails:rails | 2.0.0 |
| rubyonrails:rails | 2.0.0:rc1 |
| rubyonrails:rails | 2.0.0:rc2 |
| rubyonrails:rails | 2.0.1 |
| rubyonrails:rails | 2.0.2 |
| rubyonrails:rails | 2.0.4 |
| rubyonrails:rails | 2.1.0 |
| rubyonrails:rails | 2.1.1 |
| rubyonrails:rails | 2.1.2 |
| rubyonrails:rails | 2.2.0 |
| rubyonrails:rails | 2.2.1 |
| rubyonrails:rails | 2.2.2 |
| rubyonrails:rails | 2.3.2 |
| rubyonrails:rails | 2.3.3 |
| rubyonrails:rails | 2.3.4 |
| rubyonrails:rails | 2.3.9 |
| rubyonrails:rails | 2.3.10 |
| rubyonrails:rails | 2.3.11 |
| rubyonrails:rails | 3.0.0 |
| rubyonrails:rails | 3.0.0:beta |
| rubyonrails:rails | 3.0.0:beta2 |
| rubyonrails:rails | 3.0.0:beta3 |
| rubyonrails:rails | 3.0.0:beta4 |
| rubyonrails:rails | 3.0.0:rc |
| rubyonrails:rails | 3.0.0:rc2 |
| rubyonrails:rails | 3.0.1 |
| rubyonrails:rails | 3.0.1:pre |
| rubyonrails:rails | 3.0.2 |
| rubyonrails:rails | 3.0.2:pre |
| rubyonrails:rails | 3.0.3 |
| rubyonrails:rails | 3.0.4:rc1 |
| rubyonrails:rails | 3.0.5 |
| rubyonrails:rails | 3.0.5:rc1 |
| rubyonrails:rails | 3.0.6 |
| rubyonrails:rails | 3.0.6:rc1 |
| rubyonrails:rails | 3.0.6:rc2 |
| rubyonrails:rails | 3.0.7 |
| rubyonrails:rails | 3.0.7:rc1 |
| rubyonrails:rails | 3.0.7:rc2 |
| rubyonrails:rails | 3.0.8:rc1 |
| rubyonrails:rails | 3.0.8:rc2 |
| rubyonrails:rails | 3.0.8:rc3 |
| rubyonrails:rails | 3.0.8:rc4 |
| rubyonrails:ruby_on_rails | 3.0.4 |
| rubyonrails:rails | 3.1.0 |
| rubyonrails:rails | 3.1.0:beta1 |
| rubyonrails:rails | 3.1.0:rc1 |
Packages (OSV)
| Advisory | Ecosystem | Package | Affected | Fixed in |
|---|---|---|---|---|
| GHSA-v9v4-7jp6-8c73 | RubyGems | actionpack | >=2.0.0 <2.3.12 | 2.3.12 |
| GHSA-v9v4-7jp6-8c73 | RubyGems | actionpack | >=3.0.0 <3.0.8 | 3.0.8 |
| GHSA-v9v4-7jp6-8c73 | RubyGems | activesupport | >=2.0.0 <2.3.12 | 2.3.12 |
| GHSA-v9v4-7jp6-8c73 | RubyGems | activesupport | >=3.0.0 <3.0.8 | 3.0.8 |
Attack patterns (CAPEC)
- CAPEC-63 Cross-Site Scripting (XSS) Likelihood: High · Severity: Very High
- CAPEC-85 AJAX Footprinting Likelihood: High · Severity: Low
- CAPEC-209 XSS Using MIME Type Mismatch Severity: Medium
- CAPEC-588 DOM-Based XSS Likelihood: High · Severity: Very High
- CAPEC-591 Reflected XSS Likelihood: High · Severity: Very High
- CAPEC-592 Stored XSS Likelihood: High · Severity: Very High
The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.
References
- http://groups.google.com/group/rubyonrails-security/msg/663b600d4471e0d4?dmode=source&output=gplain
- http://openwall.com/lists/oss-security/2011/06/09/2
- http://openwall.com/lists/oss-security/2011/06/13/9
- http://weblog.rubyonrails.org/2011/6/8/potential-xss-vulnerability-in-ruby-on-rails-applications
- http://secunia.com/advisories/44789
- http://lists.fedoraproject.org/pipermail/package-announce/2011-July/062514.html
- http://lists.fedoraproject.org/pipermail/package-announce/2011-June/062090.html