First published: Thu Apr 14 2022(Updated: )
A double free was found in the Regexp compiler in Ruby 3.x before 3.0.4 and 3.1.x before 3.1.2. If a victim attempts to create a Regexp from untrusted user input, an attacker may be able to write to unexpected memory locations.
Credit: cve@mitre.org cve@mitre.org
Affected Software | Affected Version | How to fix |
---|---|---|
redhat/ruby | <0:3.0.4-160.el9_0 | 0:3.0.4-160.el9_0 |
redhat/rh-ruby30-ruby | <0:3.0.4-149.el7 | 0:3.0.4-149.el7 |
Ruby-lang Ruby | >=3.0.0<3.0.4 | |
redhat/ruby | <3.0.4 | 3.0.4 |
redhat/ruby | <3.1.2 | 3.1.2 |
debian/ruby2.7 | 2.7.4-1+deb11u1 |
Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.
(Appears in the following advisories)
CVE-2022-28738 is a double-free vulnerability found in Ruby, specifically in the Regexp compiler.
CVE-2022-28738 allows an attacker to write to unexpected memory locations if a victim attempts to create a Regexp from untrusted user input.
Ruby 3.x before 3.0.4 and 3.1.x before 3.1.2 are affected by CVE-2022-28738.
CVE-2022-28738 has a severity value of 9.8, which is considered critical.
To fix CVE-2022-28738, update Ruby to version 3.0.4 or 3.1.2, depending on the affected version.