CVE-2013-4164 Memory corruption in n/a

Medium 6.8 Published Updated

Heap-based buffer overflow in Ruby allows attackers to cause denial of service or execute arbitrary code via crafted floating-point strings.

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-4164?

CVE-2013-4164 is a medium-severity memory corruption vulnerability in Ruby-Lang Ruby, published on 23 Nov 2013. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official 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.

Weakness: CWE-119

Which versions are affected by CVE-2013-4164?

It affects 1 product.

Linux distribution packages (40)
ruby Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-debuginfo Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-devel Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-docs Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-irb Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-libs Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-rdoc Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-ri Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-static Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby-tcltk Red Hat:enterprise_linux:6::clientAll versions0:1.8.7.352-13.el6
ruby Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-debuginfo Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-devel Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-docs Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-irb Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-libs Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-rdoc Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-ri Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-static Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby-tcltk Red Hat:enterprise_linux:6::computenodeAll versions0:1.8.7.352-13.el6
ruby Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-debuginfo Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-devel Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-docs Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-irb Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-libs Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-rdoc Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-ri Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-static Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby-tcltk Red Hat:enterprise_linux:6::serverAll versions0:1.8.7.352-13.el6
ruby Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-debuginfo Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-devel Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-docs Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-irb Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-libs Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-rdoc Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-ri Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-static Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6
ruby-tcltk Red Hat:enterprise_linux:6::workstationAll versions0:1.8.7.352-13.el6

Products include Ruby-Lang Ruby.

How do I fix CVE-2013-4164?

Upgrade to a fixed version.

Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.

Is CVE-2013-4164 being exploited?

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

Public exploit code: 1 Metasploit module.

All Ruby-Lang Ruby vulnerabilities

Sources

Also known as DSA-2810-1, GHSA-j98q-m2w8-57rc, MGASA-2014-0003, RHSA-2013:1763, RHSA-2013:1764, RHSA-2013:1767 and 2 more.

Is CVE-2013-4164 in your software?

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

Check your SBOMs for free