A Directory Traversal issue was discovered in RubyGems 2.7.6 and later through 3.0.2.
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- High
- Impact type
- —
- Confidentiality · integrity · availability
- None · High · High
- Fix status
- Partial Red Hat: 9 fixed, 1 without a fix
Attack profile from CVSS 3.0 · NVD. Fix status from CNA, GitHub and Red Hat.
Summary
A Directory Traversal issue was discovered in RubyGems 2.7.6 and later through 3.0.2. Before making new directories or touching files (which now include path-checking code for symlinks), it would delete the target destination. If that destination was hidden behind a symlink, a malicious gem could delete arbitrary files on the user's machine, presuming the attacker could guess at paths. Given how frequently gem is run as sudo, and how predictable paths are on modern systems (/tmp, /usr, etc.), this could likely lead to data loss or an unusable system.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | — | all versions | — | No fix listed | CNA |
| — | rubygems-update (RubyGems) | 2.7.6 to before 2.7.9 | 2.7.9 | Patch available | GHSA-5x32-c9mf-49cc |
| — | rubygems-update (RubyGems) | 3.0.0 to before 3.0.3 | 3.0.3 | Patch available | GHSA-5x32-c9mf-49cc |
- — Vendor— Affected all versions Fixed in — No fix listed CNA
- rubygems-update (RubyGems) Vendor— Affected 2.7.6 to before 2.7.9 Fixed in 2.7.9 Patch available GHSA-5x32-c9mf-49cc
- rubygems-update (RubyGems) Vendor— Affected 3.0.0 to before 3.0.3 Fixed in 3.0.3 Patch available GHSA-5x32-c9mf-49cc
Remediation
- Fix · GHSA-5x32-c9mf-49cc rubygems-update (RubyGems) Fixed in 2.7.9 Advisory →
- Fix · GHSA-5x32-c9mf-49cc rubygems-update (RubyGems) Fixed in 3.0.3 Advisory →
Red Hat 3 advisories
- RHSA-2019:1429 Released 2019-06-11 · Red Hat rating ImportantCloudForms 4.7.5 security, bug fix and enhancement update
- CloudForms Management Engine 5.10 cfme-5.10.5.1-1.el7cf, cfme-amazon-smartstate-5.10.5.1-1.el7cf, cfme-appliance-5.10.5.1-1.el7cf +22
- RHSA-2019:1150 Released 2019-05-13 · Red Hat rating Importantrh-ruby24-ruby security, bug fix, and enhancement update
- Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 6) rh-ruby24-ruby-2.4.6-92.el6, rh-ruby24-ruby-devel-2.4.6-92.el6, rh-ruby24-ruby-doc-2.4.6-92.el6 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 7) rh-ruby24-ruby-2.4.6-92.el7, rh-ruby24-ruby-devel-2.4.6-92.el7, rh-ruby24-ruby-doc-2.4.6-92.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.4) rh-ruby24-ruby-2.4.6-92.el7, rh-ruby24-ruby-devel-2.4.6-92.el7, rh-ruby24-ruby-doc-2.4.6-92.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.5) rh-ruby24-ruby-2.4.6-92.el7, rh-ruby24-ruby-devel-2.4.6-92.el7, rh-ruby24-ruby-doc-2.4.6-92.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.6) rh-ruby24-ruby-2.4.6-92.el7, rh-ruby24-ruby-devel-2.4.6-92.el7, rh-ruby24-ruby-doc-2.4.6-92.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 6) rh-ruby24-ruby-2.4.6-92.el6, rh-ruby24-ruby-devel-2.4.6-92.el6, rh-ruby24-ruby-doc-2.4.6-92.el6 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 7) rh-ruby24-ruby-2.4.6-92.el7, rh-ruby24-ruby-devel-2.4.6-92.el7, rh-ruby24-ruby-doc-2.4.6-92.el7 +17
- RHSA-2019:1148 Released 2019-05-13 · Red Hat rating Importantrh-ruby25-ruby security, bug fix, and enhancement update
- Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 7) rh-ruby25-ruby-2.5.5-7.el7, rh-ruby25-ruby-devel-2.5.5-7.el7, rh-ruby25-ruby-doc-2.5.5-7.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.4) rh-ruby25-ruby-2.5.5-7.el7, rh-ruby25-ruby-devel-2.5.5-7.el7, rh-ruby25-ruby-doc-2.5.5-7.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.5) rh-ruby25-ruby-2.5.5-7.el7, rh-ruby25-ruby-devel-2.5.5-7.el7, rh-ruby25-ruby-doc-2.5.5-7.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.6) rh-ruby25-ruby-2.5.5-7.el7, rh-ruby25-ruby-devel-2.5.5-7.el7, rh-ruby25-ruby-doc-2.5.5-7.el7 +17
- Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 7) rh-ruby25-ruby-2.5.5-7.el7, rh-ruby25-ruby-devel-2.5.5-7.el7, rh-ruby25-ruby-doc-2.5.5-7.el7 +17
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Software Collections | Affected | No fix planned: Will not fix |
| CloudForms Management Engine 5.10 | Fixed | RHSA-2019:1429 |
| Red Hat Enterprise Linux AppStream (v. 8) | Fixed | — |
| Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 6) | Fixed | RHSA-2019:1150 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 7) | Fixed | RHSA-2019:1148, RHSA-2019:1150 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.4) | Fixed | RHSA-2019:1148, RHSA-2019:1150 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.5) | Fixed | RHSA-2019:1148, RHSA-2019:1150 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.6) | Fixed | RHSA-2019:1148, RHSA-2019:1150 |
| Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 6) | Fixed | RHSA-2019:1150 |
| Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 7) | Fixed | RHSA-2019:1148, RHSA-2019:1150 |
Not affected: 3 products
- Red Hat Enterprise Linux 6
- Red Hat Enterprise Linux 7
- Red Hat Software Collections
Timeline
- 2026-10-02 Threatist record created from CVE-2019-8320
- 2026-10-03 Alias added: GHSA-5x32-c9mf-49cc
References
Exploit 1
Advisory 4
More Rubygems vulnerabilities
- TI-2017-00851 Deserialization of untrusted data in HackerOne RubyGems CVSS 3.0CRITICAL 9.8
- TI-2017-00849 Path traversal in HackerOne RubyGems CVSS 3.0HIGH 7.5
- TI-2017-00847 Code injection in HackerOne RubyGems CVSS 3.0CRITICAL 9.8
- TI-2018-15731 RubyGems version Ruby 2.2 series: 2.2.9 and earlier, Ruby 2.3 series: 2.3.6 and earlier… CVSS 3.0CRITICAL 9.8
- TI-2019-05977 An issue was discovered in RubyGems 2.6 and later through 3.0.2. CVSS 3.1HIGH 8.8
- TI-2017-00848 RubyGems version 2.6.12 and earlier is vulnerable to maliciously crafted gem… CVSS 3.0HIGH 7.5
Sources
- CVE-2019-8320 · CVE Program
- CVE-2019-8320 · NVD
- FIRST EPSS
- GHSA-5x32-c9mf-49cc · GitHub Advisory Database · CC BY 4.0
- CVE-2019-8320 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences