CVE-2013-0333: Activesupport Activesupport Vulnerability

HIGH
Advisory Identifier: GHSA-xgr2-v94m-rc9g
CWE-74
Published
Advisory Summary

CVE-2013-0333 is a HIGH activesupport vulnerability (CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')) affecting Activesupport libraries in the RubyGems ecosystem. The issue involves activesupport in rails vulnerable to incorrect data conversion. Remediation is available by upgrading affected packages to version 2.3.16, 3.0.20.

CVE-2013-0333 at a Glance

CVE Identifier CVE-2013-0333
GHSA Identifier GHSA-xgr2-v94m-rc9g
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')
Affected Product Activesupport
Package Ecosystem RubyGems
Published Date
Last Updated

How to Fix CVE-2013-0333

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

activesupport fixed: 2.3.16
Upgrade activesupport to 2.3.16
activesupport fixed: 3.0.20
Upgrade activesupport to 3.0.20
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 activesupport

How to Check if You Are Affected

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

inspect dependencies for activesupport

Analyze the terminal output to locate any version of Activesupport in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.3.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-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection'), where the product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component. In Activesupport, 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

`lib/active_support/json/backends/yaml.rb` in Ruby on Rails 2.3.x before 2.3.16 and 3.0.x before 3.0.20 does not properly convert JSON data to YAML data for processing by a YAML parser, which allows remote attackers to execute arbitrary code, conduct SQL injection attacks, or bypass authentication via crafted data that triggers unsafe decoding, a different vulnerability than CVE-2013-0156.

CVE-2013-0333 Affected Activesupport Versions

2 component(s)
Fixed Versions:
2.3.163.0.20
Product / Package Ecosystem Affected Versions Fixed Version
activesupport
RubyGems
≥ 2.3.2
< 2.3.16
2.3.16
activesupport
RubyGems
≥ 3.0.0
< 3.0.20
3.0.20

References

NVD — CVE-2013-0333 NVD
https://nvd.nist.gov/vuln/detail/CVE-2013-0333
access.redhat.com/errata/rhsa-2013:02... WEB
https://access.redhat.com/errata/RHSA-2013:0201
access.redhat.com/errata/rhsa-2013:02... WEB
https://access.redhat.com/errata/RHSA-2013:0202
access.redhat.com/errata/rhsa-2013:02... WEB
https://access.redhat.com/errata/RHSA-2013:0203
Activesupport Security Information SECURITY
https://access.redhat.com/security/cve/CVE-2013-0333
bugzilla.redhat.com/show_bug.cgi WEB
https://bugzilla.redhat.com/show_bug.cgi?id=903440
GitHub Advisory / Wiki ADVISORY
https://github.com/advisories/GHSA-xgr2-v94m-rc9g
Activesupport Source Repository REPOSITORY
https://github.com/rubysec/ruby-advisory-db/blob/master/gems/activesupport/CVE-2013-0333.yml
groups.google.com/forum/ WEB
https://groups.google.com/forum/?fromgroups=#!topic/rubyonrails-security/1h2DR63ViGo
Activesupport Security Information SECURITY
https://groups.google.com/group/rubyonrails-security/msg/52179af76915e518?dmode=source&output=gplain
Activesupport Security Information SECURITY
https://puppet.com/security/cve/cve-2013-0333
Activesupport Security Information SECURITY
http://lists.apple.com/archives/security-announce/2013/Jun/msg00000.html
Activesupport Security Information SECURITY
http://lists.apple.com/archives/security-announce/2013/Mar/msg00002.html
rhn.redhat.com/errata/rhsa-2013-02... WEB
http://rhn.redhat.com/errata/RHSA-2013-0201.html
rhn.redhat.com/errata/rhsa-2013-02... WEB
http://rhn.redhat.com/errata/RHSA-2013-0202.html
rhn.redhat.com/errata/rhsa-2013-02... WEB
http://rhn.redhat.com/errata/RHSA-2013-0203.html
support.apple.com/kb/ht5784 WEB
http://support.apple.com/kb/HT5784
weblog.rubyonrails.org/2013/1/28/rails-3-0... WEB
http://weblog.rubyonrails.org/2013/1/28/Rails-3-0-20-and-2-3-16-have-been-released
Activesupport Security Information SECURITY
http://www.debian.org/security/2013/dsa-2613
www.kb.cert.org/vuls/id/628463 WEB
http://www.kb.cert.org/vuls/id/628463

Frequently Asked Questions

What is CVE-2013-0333?
CVE-2013-0333 is a security vulnerability in Activesupport involving activesupport in Rails vulnerable to incorrect data conversion under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection').
Which Activesupport versions are affected?
Affected versions include releases prior to 2.3.16, 3.0.20 across affected packages: activesupport.
What version fixes CVE-2013-0333?
Upgrading to 2.3.16, 3.0.20 (or the latest patched release for your respective branch) resolves the vulnerability.
Is activesupport affected?
Yes, activesupport is affected in releases prior to 2.3.16, 3.0.20. Upgrade your dependency to 2.3.16, 3.0.20 or later.
What CWE is associated with CVE-2013-0333?
CVE-2013-0333 is classified under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection') (The product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component.).
How can I check RubyGems dependencies for CVE-2013-0333?
Run the dependency tree command: 'inspect dependencies for activesupport'. 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-xgr2-v94m-rc9g",
  "modified" : "2023-08-25T20:10:51Z",
  "published" : "2017-10-24T18:33:37Z",
  "aliases" : [ "CVE-2013-0333" ],
  "summary" : "activesupport in Rails vulnerable to incorrect data conversion",
  "details" : "`lib/active_support/json/backends/yaml.rb` in Ruby on Rails 2.3.x before 2.3.16 and 3.0.x before 3.0.20 does not properly convert JSON data to YAML data for processing by a YAML parser, which allows remote attackers to execute arbitrary code, conduct SQL injection attacks, or bypass authentication via crafted data that triggers unsafe decoding, a different vulnerability than CVE-2013-0156.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "activesupport"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.3.2"
      }, {
        "fixed" : "2.3.16"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "activesupport"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.0.0"
      }, {
        "fixed" : "3.0.20"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2013-0333"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2013:0201"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2013:0202"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2013:0203"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/security/cve/CVE-2013-0333"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.redhat.com/show_bug.cgi?id=903440"
  }, {
    "type" : "ADVISORY",
    "url" : "https://github.com/advisories/GHSA-xgr2-v94m-rc9g"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/activesupport/CVE-2013-0333.yml"
  }, {
    "type" : "WEB",
    "url" : "https://groups.google.com/forum/?fromgroups=#!topic/rubyonrails-security/1h2DR63ViGo"
  }, {
    "type" : "WEB",
    "url" : "https://groups.google.com/group/rubyonrails-security/msg/52179af76915e518?dmode=source&output=gplain"
  }, {
    "type" : "WEB",
    "url" : "https://puppet.com/security/cve/cve-2013-0333"
  }, {
    "type" : "WEB",
    "url" : "http://lists.apple.com/archives/security-announce/2013/Jun/msg00000.html"
  }, {
    "type" : "WEB",
    "url" : "http://lists.apple.com/archives/security-announce/2013/Mar/msg00002.html"
  }, {
    "type" : "WEB",
    "url" : "http://rhn.redhat.com/errata/RHSA-2013-0201.html"
  }, {
    "type" : "WEB",
    "url" : "http://rhn.redhat.com/errata/RHSA-2013-0202.html"
  }, {
    "type" : "WEB",
    "url" : "http://rhn.redhat.com/errata/RHSA-2013-0203.html"
  }, {
    "type" : "WEB",
    "url" : "http://support.apple.com/kb/HT5784"
  }, {
    "type" : "WEB",
    "url" : "http://weblog.rubyonrails.org/2013/1/28/Rails-3-0-20-and-2-3-16-have-been-released"
  }, {
    "type" : "WEB",
    "url" : "http://www.debian.org/security/2013/dsa-2613"
  }, {
    "type" : "WEB",
    "url" : "http://www.kb.cert.org/vuls/id/628463"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-74" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-06-16T22:03:24Z",
    "nvd_published_at" : "2013-01-30T12:00:00Z"
  }
}