CVE-2013-0155 Active Record allows bypassing of database-query restrictions
Remote attackers can bypass database restrictions and manipulate queries via crafted JSON requests, potentially reading or modifying data.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2013-0155?
CVE-2013-0155 is a medium-severity SQL injection vulnerability in Debian Debian Linux, published on 13 Jan 2013. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
Ruby on Rails 3.0.x before 3.0.19, 3.1.x before 3.1.10, and 3.2.x before 3.2.11 does not properly consider differences in parameter handling between the Active Record component and the JSON implementation, which allows remote attackers to bypass intended database-query restrictions and perform NULL checks or trigger missing WHERE clauses via a crafted request, as demonstrated by certain "[nil]" values, a related issue to CVE-2012-2660 and CVE-2012-2694.
Weakness: CWE-264
Which versions are affected by CVE-2013-0155?
6 open source packages ship an affected version, including activerecord. It affects 3 products.
| Package | Affected | Fixed in |
|---|---|---|
activerecord RubyGems | From 3.0.0 | 3.0.19 |
activerecord RubyGems | From 3.0.0 | 3.0.19 |
activerecord RubyGems | From 3.1.0 | 3.1.10 |
activerecord RubyGems | From 3.1.0 | 3.1.10 |
activerecord RubyGems | From 3.2.0 | 3.2.11 |
activerecord RubyGems | From 3.2.0 | 3.2.11 |
Products include Debian Debian Linux, Rubyonrails Rails, Rubyonrails Ruby on Rails.
How do I fix CVE-2013-0155?
Upgrade activerecord to a fixed version for your release line: 3.0.19, 3.1.10 or 3.2.11.
Use parameterised queries everywhere and never build SQL by joining strings. Upgrade affected software first; a web application firewall only buys time. More about SQL injection.
Is CVE-2013-0155 being exploited?
There is no known exploitation of CVE-2013-0155 in the wild and no public exploit code.
Other vulnerabilities in Debian Debian Linux
Sources
Also known as DEBIAN-CVE-2013-0155, DSA-2609-1, GHSA-gppp-5xc5-wfpx.