CVE-2013-4164

Ruby 1.8 1.9-1.9.3-p484 2.0-2.0.0-p353 2.1-2.1.0 preview2 - Heap-based Buffer Overflow via String to Float Conversion

Title source: llm
STIX 2.1

Exploitation Summary

EIP tracks 1 public exploit for CVE-2013-4164. PoCs published by Charlie Somerville, joev, todb, including Metasploit module auxiliary/dos/http/rails_json_float_dos.

AI-analyzed exploit summary This Metasploit module exploits a heap-based buffer overflow in Ruby on Rails (CVE-2013-4164) by sending a maliciously crafted JSON payload with an extremely large floating-point number, causing a denial-of-service (DoS) via segmentation fault.

Description

Heap-based buffer overflow in Ruby 1.8, 1.9 before 1.9.3-p484, 2.0 before 2.0.0-p353, 2.1 before 2.1.0 preview2, and trunk before revision 43780 allows context-dependent attackers to cause a denial of service (segmentation fault) and possibly execute arbitrary code via a string that is converted to a floating point value, as demonstrated using (1) the to_f method or (2) JSON.parse.

Exploits (1)

metasploit WORKING POC
by Charlie Somerville, joev, todb · rubypoc
https://github.com/rapid7/metasploit-framework/blob/master/modules/auxiliary/dos/http/rails_json_float_dos.rb

This Metasploit module exploits a heap-based buffer overflow in Ruby on Rails (CVE-2013-4164) by sending a maliciously crafted JSON payload with an extremely large floating-point number, causing a denial-of-service (DoS) via segmentation fault.

Classification
Working Poc 100%
Attack Type
Dos
Complexity
Trivial
Reliability
Reliable
Target: Ruby on Rails (Ruby 1.9.3-p448 and others)
No auth needed
Prerequisites: Vulnerable Ruby version · Exposed Rails application endpoint
devstral-2 · analyzed Feb 16, 2026 Full analysis →

References (22)

Core 22
Core References
Vendor Advisory vendor-advisory x_refsource_redhat
http://rhn.redhat.com/errata/RHSA-2014-0215.html
Vendor Advisory vendor-advisory x_refsource_redhat
http://rhn.redhat.com/errata/RHSA-2013-1763.html
Vendor Advisory vendor-advisory x_refsource_redhat
http://rhn.redhat.com/errata/RHSA-2013-1764.html
Vendor Advisory vendor-advisory x_refsource_redhat
http://rhn.redhat.com/errata/RHSA-2013-1767.html
Vendor Advisory vendor-advisory x_refsource_redhat
http://rhn.redhat.com/errata/RHSA-2014-0011.html
Vendor Advisory vendor-advisory x_refsource_ubuntu
http://www.ubuntu.com/usn/USN-2035-1
Various Sources x_refsource_confirm
https://puppet.com/security/cve/cve-2013-4164
Third Party Advisory vendor-advisory x_refsource_apple
http://archives.neohapsis.com/archives/bugtraq/2014-10/0103.html
Mailing List vendor-advisory x_refsource_suse
http://lists.opensuse.org/opensuse-updates/2013-12/msg00028.html
Third Party Advisory vendor-advisory x_refsource_apple
http://archives.neohapsis.com/archives/bugtraq/2014-04/0134.html
Third Party Advisory, VDB Entry vdb-entry x_refsource_bid
http://www.securityfocus.com/bid/63873
Mailing List vendor-advisory x_refsource_suse
http://lists.opensuse.org/opensuse-updates/2013-12/msg00027.html
Vendor Advisory x_refsource_confirm
https://support.apple.com/kb/HT6536
Third Party Advisory, VDB Entry vdb-entry x_refsource_osvdb
http://osvdb.org/100113
Third Party Advisory vendor-advisory x_refsource_debian
http://www.debian.org/security/2013/dsa-2810
Third Party Advisory third-party-advisory x_refsource_secunia
http://secunia.com/advisories/57376
Third Party Advisory vendor-advisory x_refsource_debian
http://www.debian.org/security/2013/dsa-2809
Vendor Advisory third-party-advisory x_refsource_secunia
http://secunia.com/advisories/55787

Scores

EPSS 0.1196
EPSS Percentile 93.9%

Details

CWE
CWE-119
Status published
Products (7)
ruby-lang/ruby 1.8
ruby-lang/ruby 1.9
ruby-lang/ruby 1.9.1
ruby-lang/ruby 1.9.2
ruby-lang/ruby 1.9.3
ruby-lang/ruby 2.0.0
ruby-lang/ruby 2.1 preview1
Published Nov 23, 2013
Tracked Since Feb 18, 2026