GHSA-gppp-5xc5-wfpx CVE-2013-0155
Active Record allows bypassing of database-query restrictions
- Severity
- Medium
- The publisher's own rating, not a CVSS score
- Exploit chance (EPSS)
- 8.24%
- Chance of exploitation in the next 30 days. Higher than 94.90% of scored vulnerabilities.
- Known exploited
- No
- Not in CISA's catalog
- Weakness
- CWE-284 Improper Access Control
- Fix
3.0.19- Upgrade activerecord to this version or later
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.
Affected versions
RubyGems
| Package | Vulnerable | Fixed in |
|---|---|---|
| activerecord | >= 3.0.0, < 3.0.19 |
3.0.19 |
| activerecord | >= 3.1.0, < 3.1.10 |
3.1.10 |
| activerecord | >= 3.2.0, < 3.2.11 |
3.2.11 |
How to fix
Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.
activerecord RubyGems → 3.0.19
- bundler
bundle update activerecord # Gemfile: gem "activerecord", ">= 3.0.19"
Weakness
CWE-284: Improper Access Control
The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.
How to prevent it
- Architecture and Design, Operation: Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
- Architecture and Design: Compartmentalize the system to have "safe" areas where trust boundaries can be unambiguously drawn. Do not allow sensitive data to go outside of the trust boundary and always be careful when interfacing with a compartment outside of the safe area. Ensure that appropriate compartmentalization is built into the system design, and the compartmentalization allows for and reinforces privilege separation functionality. Architects and designers should rely on the principle of least privilege to decide the appropriate time to use privileges and the time to drop privileges.
References
Advisories
Other links
- github.com/rubysec/ruby-advisory-db/blob/master/gems/activerecord/CVE-2013-0155…
- groups.google.com/group/rubyonrails-security/msg/bc6f13dafe130ee9
- ics-cert.us-cert.gov/advisories/ICSA-13-036-01A
- lists.apple.com/archives/security-announce/2013/Jun/msg00000.html
- lists.opensuse.org/opensuse-updates/2013-12/msg00079.html
- lists.opensuse.org/opensuse-updates/2013-12/msg00081.html
- lists.opensuse.org/opensuse-updates/2013-12/msg00082.html
- lists.opensuse.org/opensuse-updates/2014-01/msg00003.html
- rhn.redhat.com/errata/RHSA-2013-0154.html
- support.apple.com/kb/HT5784
- debian.org/security/2013/dsa-2609
Timeline
- Published
- Last updated by the source
- Latest EPSS score
Related advisories
| Advisory | Severity | Why it's related |
|---|---|---|
| GHSA-76r7-hhxj-r776 Active Record logging vulnerable to ANSI escape injection | Medium | Also affects activerecord |
| GHSA-579w-22j4-4749 Denial of Service Vulnerability in ActiveRecord's PostgreSQL adapter | High | Also affects activerecord |
| GHSA-hq7p-j377-6v63 SQL Injection Vulnerability via ActiveRecord comments | High | Also affects activerecord |
| GHSA-3hhc-qp5v-9p2j Active Record RCE bug with Serialized Columns | Critical | Also affects activerecord |
| GHSA-f57c-hx33-hvh8 Active Record component in Ruby on Rails has a data-type injection vulnerability | Critical | Also affects activerecord |
| GHSA-8hc4-xxm3-5ppp Active Record subject to Regular Expression Denial-of-Service (ReDoS) | High | Also affects activerecord |
| GHSA-xf96-32q2-9rw2 Rails ActiveRecord gem vulnerable to SQL injection | High | Also affects activerecord |
| GHSA-jmm9-2p29-vh2w activerecord vulnerable to SQL Injection | High | Also affects activerecord |
MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.
Check your repos with MergeHarbor