CVE-2013-6417: Actionpack Actionpack Allows Bypass Of Database-query Vulnerability

MODERATE
Advisory Identifier: GHSA-wpw7-wxjm-cw8r
CWE-284
Published
Advisory Summary

CVE-2013-6417 is a MODERATE actionpack allows bypass of database-query vulnerability (CWE-284: Improper Access Control) affecting Actionpack libraries in the RubyGems ecosystem. The issue involves actionpack allows bypass of database-query restrictions. Remediation is available by upgrading affected packages to version 3.2.16, 4.0.2.

CVE-2013-6417 at a Glance

CVE Identifier CVE-2013-6417
GHSA Identifier GHSA-wpw7-wxjm-cw8r
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-284: Improper Access Control
Affected Product Actionpack
Package Ecosystem RubyGems
Published Date
Last Updated

How to Fix CVE-2013-6417

To remediate this vulnerability, upgrade all affected Actionpack dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

actionpack fixed: 3.2.16
Upgrade actionpack to 3.2.16
actionpack fixed: 4.0.2
Upgrade actionpack to 4.0.2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for actionpack

How to Check if You Are Affected

To determine whether your application is affected by CVE-2013-6417, inspect your project dependencies for Actionpack:

inspect dependencies for actionpack

Analyze the terminal output to locate any version of Actionpack in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.2.16), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In Actionpack, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

`actionpack/lib/action_dispatch/http/request.rb` in Ruby on Rails before 3.2.16 and 4.x before 4.0.2 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 that leverages (1) third-party Rack middleware or (2) custom Rack middleware. NOTE: this vulnerability exists because of an incomplete fix for CVE-2013-0155.

CVE-2013-6417 Affected Actionpack Versions

2 component(s)
Fixed Versions:
3.2.164.0.2
Product / Package Ecosystem Affected Versions Fixed Version
actionpack
RubyGems
≥ 3.0.0
< 3.2.16
3.2.16
actionpack
RubyGems
≥ 4.0.0
< 4.0.2
4.0.2

References

NVD — CVE-2013-6417 NVD
https://nvd.nist.gov/vuln/detail/CVE-2013-6417
Actionpack Source Repository REPOSITORY
https://github.com/rails/rails
Actionpack Source Repository REPOSITORY
https://github.com/rubysec/ruby-advisory-db/blob/master/gems/actionpack/CVE-2013-6417.yml
groups.google.com/forum/ WEB
https://groups.google.com/forum/#!topic/ruby-security-ann/niK4drpSHT4
groups.google.com/forum/message/raw WEB
https://groups.google.com/forum/message/raw?msg=ruby-security-ann/niK4drpSHT4/g8JW8ZsayRkJ
Actionpack Security Information SECURITY
https://puppet.com/security/cve/cve-2013-6417
Actionpack Security Information SECURITY
https://web.archive.org/web/20160806051251/https://puppet.com/security/cve/cve-2013-6417
lists.opensuse.org/opensuse-updates/20... WEB
http://lists.opensuse.org/opensuse-updates/2013-12/msg00079.html
lists.opensuse.org/opensuse-updates/20... WEB
http://lists.opensuse.org/opensuse-updates/2013-12/msg00081.html
lists.opensuse.org/opensuse-updates/20... WEB
http://lists.opensuse.org/opensuse-updates/2013-12/msg00082.html
lists.opensuse.org/opensuse-updates/20... WEB
http://lists.opensuse.org/opensuse-updates/2014-01/msg00003.html
rhn.redhat.com/errata/rhsa-2013-17... WEB
http://rhn.redhat.com/errata/RHSA-2013-1794.html
rhn.redhat.com/errata/rhsa-2014-00... WEB
http://rhn.redhat.com/errata/RHSA-2014-0008.html
rhn.redhat.com/errata/rhsa-2014-04... WEB
http://rhn.redhat.com/errata/RHSA-2014-0469.html
weblog.rubyonrails.org/2013/12/3/rails_3_2... WEB
http://weblog.rubyonrails.org/2013/12/3/Rails_3_2_16_and_4_0_2_have_been_released
Actionpack Security Information SECURITY
http://www.debian.org/security/2014/dsa-2888

Frequently Asked Questions

What is CVE-2013-6417?
CVE-2013-6417 is a security vulnerability in Actionpack involving actionpack allows bypass of database-query restrictions under CWE-284: Improper Access Control.
Which Actionpack versions are affected?
Affected versions include releases prior to 3.2.16, 4.0.2 across affected packages: actionpack.
What version fixes CVE-2013-6417?
Upgrading to 3.2.16, 4.0.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is actionpack affected?
Yes, actionpack is affected in releases prior to 3.2.16, 4.0.2. Upgrade your dependency to 3.2.16, 4.0.2 or later.
What CWE is associated with CVE-2013-6417?
CVE-2013-6417 is classified under CWE-284: Improper Access Control (The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.).
How can I check RubyGems dependencies for CVE-2013-6417?
Run the dependency tree command: 'inspect dependencies for actionpack'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-wpw7-wxjm-cw8r",
  "modified" : "2023-08-25T19:25:00Z",
  "published" : "2017-10-24T18:33:36Z",
  "aliases" : [ "CVE-2013-6417" ],
  "summary" : "actionpack allows bypass of database-query restrictions",
  "details" : "`actionpack/lib/action_dispatch/http/request.rb` in Ruby on Rails before 3.2.16 and 4.x before 4.0.2 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 that leverages (1) third-party Rack middleware or (2) custom Rack middleware.  NOTE: this vulnerability exists because of an incomplete fix for CVE-2013-0155.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "actionpack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.0.0"
      }, {
        "fixed" : "3.2.16"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "actionpack"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.0.0"
      }, {
        "fixed" : "4.0.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2013-6417"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/rails/rails"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/actionpack/CVE-2013-6417.yml"
  }, {
    "type" : "WEB",
    "url" : "https://groups.google.com/forum/#!topic/ruby-security-ann/niK4drpSHT4"
  }, {
    "type" : "WEB",
    "url" : "https://groups.google.com/forum/message/raw?msg=ruby-security-ann/niK4drpSHT4/g8JW8ZsayRkJ"
  }, {
    "type" : "WEB",
    "url" : "https://puppet.com/security/cve/cve-2013-6417"
  }, {
    "type" : "WEB",
    "url" : "https://web.archive.org/web/20160806051251/https://puppet.com/security/cve/cve-2013-6417"
  }, {
    "type" : "WEB",
    "url" : "http://lists.opensuse.org/opensuse-updates/2013-12/msg00079.html"
  }, {
    "type" : "WEB",
    "url" : "http://lists.opensuse.org/opensuse-updates/2013-12/msg00081.html"
  }, {
    "type" : "WEB",
    "url" : "http://lists.opensuse.org/opensuse-updates/2013-12/msg00082.html"
  }, {
    "type" : "WEB",
    "url" : "http://lists.opensuse.org/opensuse-updates/2014-01/msg00003.html"
  }, {
    "type" : "WEB",
    "url" : "http://rhn.redhat.com/errata/RHSA-2013-1794.html"
  }, {
    "type" : "WEB",
    "url" : "http://rhn.redhat.com/errata/RHSA-2014-0008.html"
  }, {
    "type" : "WEB",
    "url" : "http://rhn.redhat.com/errata/RHSA-2014-0469.html"
  }, {
    "type" : "WEB",
    "url" : "http://weblog.rubyonrails.org/2013/12/3/Rails_3_2_16_and_4_0_2_have_been_released"
  }, {
    "type" : "WEB",
    "url" : "http://www.debian.org/security/2014/dsa-2888"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-284" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-06-16T22:00:55Z",
    "nvd_published_at" : "2013-12-07T00:55:00Z"
  }
}