CVE-2011-2197
rails Cross-site Scripting vulnerability
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.
Exploit likelihood
What each source reports
NVD Score used
4.3
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.
- Record
CVE-2011-2197- CVSS 2.0
- 4.3 Medium
AV:N/AC:M/Au:N/C:N/I:P/A:N - Weakness
- CWE-79
- Updated
- 2026-11-02
CVE List No score
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.
- Record
CVE-2011-2197- Updated
- 2026-11-02
EUVDEUVD-2017-0312 No score
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.
- Record
EUVD-2017-0312- Updated
- 2026-11-03
GitHub AdvisoriesGHSA-v9v4-7jp6-8c73 No score
rails Cross-site Scripting vulnerability
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.
- Record
GHSA-v9v4-7jp6-8c73- Weakness
- CWE-79
- Updated
- 2026-11-02
OSVGHSA-v9v4-7jp6-8c73 No score
rails Cross-site Scripting vulnerability
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.
- Record
GHSA-v9v4-7jp6-8c73- Weakness
- CWE-79
- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
actionpackRubyGems |
2.0.0 up to 2.3.11 | 2.3.11 |
actionpackRubyGems |
3.0.0 up to 3.0.7 | 3.0.7 |
activesupportRubyGems |
2.0.0 up to 2.3.11 | 2.3.11 |
activesupportRubyGems |
3.0.0 up to 3.0.7 | 3.0.7 |
actionpackRubyGems |
2.0.0 up to 2.3.12, plus listed versions 2.0.12.0.22.0.42.0.52.1.0 Show 16 moreShow less2.1.12.1.22.2.22.2.32.3.102.3.112.3.22.3.32.3.42.3.52.3.62.3.72.3.82.3.8.pre12.3.92.3.9.pre |
2.3.12 |
actionpackRubyGems |
3.0.0 up to 3.0.8, plus listed versions 3.0.13.0.23.0.33.0.43.0.4.rc1 Show 11 moreShow less3.0.53.0.5.rc13.0.63.0.6.rc13.0.6.rc23.0.73.0.7.rc13.0.7.rc23.0.8.rc13.0.8.rc23.0.8.rc4 |
3.0.8 |
activesupportRubyGems |
2.0.0 up to 2.3.12, plus listed versions 2.0.12.0.22.0.42.0.52.1.0 Show 17 moreShow less2.1.12.1.22.2.22.2.32.3.102.3.112.3.22.3.32.3.42.3.52.3.62.3.6.pre2.3.72.3.82.3.8.pre12.3.92.3.9.pre |
2.3.12 |
activesupportRubyGems |
3.0.0 up to 3.0.8, plus listed versions 3.0.13.0.23.0.33.0.43.0.4.rc1 Show 11 moreShow less3.0.53.0.5.rc13.0.63.0.6.rc13.0.6.rc23.0.73.0.7.rc13.0.7.rc23.0.8.rc13.0.8.rc23.0.8.rc4 |
3.0.8 |
History
| Recorded | Changed | Sources |
|---|---|---|
| aliases | EUVD | |
| first indexed | CVE List, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2011-2197 is a medium vulnerability (CVSS 4.3) in Rubyonrails Rails, published June 30, 2011. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.96%, the 80th percentile. Fixed in actionpack 2.3.11.
References
groups.google.com/group/rubyonrails-security/msg/663b600d4471e0d4?dmode=source&output=gplain
lists.fedoraproject.org/pipermail/package-announce/2011-June/062090.html
lists.fedoraproject.org/pipermail/package-announce/2011-July/062514.html
weblog.rubyonrails.org/2011/6/8/potential-xss-vulnerability-in-ruby-on-rails-applications
secunia.com/advisories/44789
openwall.com/lists/oss-security/2011/06/09/2
Show 8 moreShow less
openwall.com/lists/oss-security/2011/06/13/9
nvd.nist.gov/vuln/detail/CVE-2011-2197
github.com/rails/rails/commit/53a2c0baf2b128dd4808eca313256f6f4bb8c4cd
github.com/rails/rails/commit/ed3796434af6069ced6a641293cf88eef3b284da
gist.github.com/NZKoz/b2ceb626fc2bcdfe497f
github.com/rubysec/ruby-advisory-db/blob/master/gems/activesupport/CVE-2011-2197.yml
github.com/advisories/GHSA-v9v4-7jp6-8c73
github.com/rails/rails