CVE-2013-0333 activesupport in Rails vulnerable to incorrect data conversion

High 7.5 Published Updated

Remote attackers can execute arbitrary code, perform SQL injection, or bypass authentication in Ruby on Rails via unsafe YAML deserialization of JSON 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-0333?

CVE-2013-0333 is a high-severity unsafe deserialization vulnerability in Rubyonrails Rails, published on 30 Jan 2013. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

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.

Which versions are affected by CVE-2013-0333?

4 open source packages ship an affected version, including activesupport. It affects 2 products.

PackageAffectedFixed in
activesupport RubyGemsFrom 2.3.22.3.16
activesupport RubyGemsFrom 2.3.22.3.16
activesupport RubyGemsFrom 3.0.03.0.20
activesupport RubyGemsFrom 3.0.03.0.20
Linux distribution packages (1)
rubygem-activesupport Red Hat:openshift:1::el6All versions1:3.0.13-4.el6op

Products include Rubyonrails Rails, Rubyonrails Ruby on Rails.

How do I fix CVE-2013-0333?

Upgrade activesupport to a fixed version for your release line: 2.3.16 or 3.0.20.

Upgrade, and only deserialise data from trusted sources or with an allow-list of types. More about Unsafe deserialization.

Is CVE-2013-0333 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2013-0333 exists.

Public exploit code: 2 Metasploit modules, 1 Exploit-DB entry and 1 proofs of concept on GitHub.

All Rubyonrails Rails vulnerabilities

Sources

Also known as DEBIAN-CVE-2013-0333, DSA-2613-1, GHSA-xgr2-v94m-rc9g, RHSA-2013:0202.

Is CVE-2013-0333 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free