Ruby: Out-of-bounds Read
CVE-2022-28739 is a high-severity out-of-bounds read vulnerability in Ruby from Ruby-lang, with a CVSS 3.1 base score of 7.5 out of 10. It can be exploited remotely over the network by an unauthenticated attacker, without any action from a user. The record lists versions 2.6.10, 2.7.6, 3.0.4 as the first without the flaw, so updating Ruby to one of those releases or later removes the exposure. There is no confirmed exploitation so far. EPSS estimates a 4.37% chance of exploitation within 30 days, which is in the top 8.58% of all scored CVEs.
High severity with no evidence of exploitation so far.
What to do
- Update Ruby to 2.6.10 or 2.7.6 or 3.0.4 or 3.1.2, whichever matches your release line, or a later version.
- Update macOS to 11.7.1 or 12.6.1, whichever matches your release line, or a later version.
- Read the advisory on ruby-lang.org for workarounds and exact fixed builds.
- Until you can update, restrict network access to the affected service so it is not reachable from untrusted networks.
Affected products and versions
| Vendor | Product | Affected versions | Fixed in |
|---|---|---|---|
| Ruby-lang | Ruby | before 2.6.10; 2.7.0 up to, but not including, 2.7.6; 3.0.0 up to, but not including, 3.0.4; 3.1.0 up to, but not including, 3.1.2 | 2.6.10, 2.7.6, 3.0.4, 3.1.2 |
| Debian | Debian Linux | 9.0; 10.0; 11.0 | Not stated |
| Apple | macOS | 11.0 up to, but not including, 11.7.1; 12.0 up to, but not including, 12.6.1 | 11.7.1, 12.6.1 |
Version data comes from NVD's product matching. Confirm against the vendor advisory before deciding you are unaffected.
How the severity score breaks down
- Attack vector
- NetworkCan be exploited remotely over a network, including the internet.
- Attack complexity
- LowNo special conditions are needed; the attack works reliably.
- Privileges required
- NoneNo account or login is needed.
- User interaction
- NoneNo action by a victim is required.
- Scope
- UnchangedImpact stays within the vulnerable component.
- Confidentiality
- HighAll data handled by the component can be read.
- Integrity
- NoneNothing can be modified.
- Availability
- NoneAvailability is not affected.
Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N. Scored by NVD.
| Scoring system | Score | Severity | Scored by |
|---|---|---|---|
| CVSS 3.1 | 7.5 | High | NVD |
| CVSS 2.0 | 4.3 | Medium | NVD |
Official description
There is a buffer over-read in Ruby before 2.6.10, 2.7.x before 2.7.6, 3.x before 3.0.4, and 3.1.x before 3.1.2. It occurs in String-to-Float conversion, including Kernel#Float and String#to_f.
Source: the CVE record as published by its numbering authority, via NVD and CVE.org.
The underlying weakness: Out-of-bounds Read
The product reads data past the end, or before the beginning, of the intended buffer.
How developers prevent this class of flaw
- Use a language that provides appropriate memory abstractions.
Timeline
- CVE record published.
- Record last changed materially (score, affected products, status or references).
References
Third-party and government advisories
- seclists.org/fulldisclosure/2022/Oct/41Mailing List, Third Party Advisory
- hackerone.com/reports/1248108Permissions Required, Third Party Advisory
- security-tracker.debian.org/tracker/CVE-2022-28739Third Party Advisory
- security.netapp.com/advisory/ntap-20220624-0002/Third Party Advisory
- support.apple.com/kb/HT213488Third Party Advisory
- support.apple.com/kb/HT213493Third Party Advisory
- support.apple.com/kb/HT213494Third Party Advisory
Other references
- seclists.org/fulldisclosure/2022/Oct/28
- seclists.org/fulldisclosure/2022/Oct/29
- seclists.org/fulldisclosure/2022/Oct/30
- seclists.org/fulldisclosure/2022/Oct/42
- lists.debian.org/debian-lts-announce/2023/06/msg00012.html
- security.gentoo.org/glsa/202401-27
- lists.debian.org/debian-lts-announce/2024/09/msg00000.html
Other vulnerabilities in Ruby
- 10.0 Critical severity
- 8.1 High severity
- 9.8 Critical severity
- 9.8 Critical severity
Recent Out-of-bounds Read vulnerabilities
- 9.3 High severity
- 7.1 High severity
- 7.1 High severity
- 7.8 High severity
- 7.1 High severity
- 7.1 High severity
Spotted an error? Tell us.