ruby: Unintentional file and directory creation with directory traversal in tempfile and tmpdir
Published Apr 3, 2018
7.5
HIGHCVSS 3.0
EPSS 10.16%
Description
Directory traversal vulnerability in the Dir.mktmpdir method in the tmpdir library in Ruby before 2.2.10, 2.3.x before 2.3.7, 2.4.x before 2.4.4, 2.5.x before 2.5.1, and 2.6.0-preview1 might allow attackers to create arbitrary directories or files via a .. (dot dot) in the prefix argument.
Affected products
No data.
Configuration 1
Configuration 2
- 14.04
- 16.04
- 17.10
Configuration 3
- 7.0
- 8.0
- 9.0
Configuration 4
- 6.0
- 7.0
- 7.4
- 7.5
- 7.6
No data.
Red Hat Enterprise Linux 7
ruby-0:2.0.0.648-36.el7
Fixed · RHSA-2019:2028
Red Hat Software Collections for Red Hat Enterprise Linux 6
rh-ruby23-ruby-0:2.3.8-69.el6
Fixed · RHSA-2018:3729
Red Hat Software Collections for Red Hat Enterprise Linux 6
rh-ruby24-ruby-0:2.4.5-91.el6
Fixed · RHSA-2018:3730
Red Hat Software Collections for Red Hat Enterprise Linux 7
rh-ruby23-ruby-0:2.3.8-69.el7
Fixed · RHSA-2018:3729
Red Hat Software Collections for Red Hat Enterprise Linux 7
rh-ruby24-ruby-0:2.4.5-91.el7
Fixed · RHSA-2018:3730
Red Hat Software Collections for Red Hat Enterprise Linux 7
rh-ruby25-ruby-0:2.5.3-6.el7
Fixed · RHSA-2018:3731
Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
rh-ruby23-ruby-0:2.3.8-69.el7
Fixed · RHSA-2018:3729
Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
rh-ruby24-ruby-0:2.4.5-91.el7
Fixed · RHSA-2018:3730
Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
rh-ruby25-ruby-0:2.5.3-6.el7
Fixed · RHSA-2018:3731
Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
rh-ruby23-ruby-0:2.3.8-69.el7
Fixed · RHSA-2018:3729
Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
rh-ruby24-ruby-0:2.4.5-91.el7
Fixed · RHSA-2018:3730
Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
rh-ruby25-ruby-0:2.5.3-6.el7
Fixed · RHSA-2018:3731
Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS
rh-ruby23-ruby-0:2.3.8-69.el7
Fixed · RHSA-2018:3729
Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS
rh-ruby24-ruby-0:2.4.5-91.el7
Fixed · RHSA-2018:3730
Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS
rh-ruby25-ruby-0:2.5.3-6.el7
Fixed · RHSA-2018:3731
CloudForms Management Engine 5
rh-ruby22-ruby
Affected
CloudForms Management Engine 5
ruby-200-ruby
Affected
Red Hat Enterprise Linux 5
ruby
Will not fix
Red Hat Enterprise Linux 6
ruby
Will not fix
Red Hat Enterprise Linux 8
ruby
Not affected
Red Hat Software Collections
rh-ruby22-ruby
Will not fix
Red Hat Subscription Asset Manager
ruby193-ruby
Will not fix
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat Enterprise Linux 7 | ruby-0:2.0.0.648-36.el7 | Fixed | RHSA-2019:2028 |
| Red Hat Software Collections for Red Hat Enterprise Linux 6 | rh-ruby23-ruby-0:2.3.8-69.el6 | Fixed | RHSA-2018:3729 |
| Red Hat Software Collections for Red Hat Enterprise Linux 6 | rh-ruby24-ruby-0:2.4.5-91.el6 | Fixed | RHSA-2018:3730 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7 | rh-ruby23-ruby-0:2.3.8-69.el7 | Fixed | RHSA-2018:3729 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7 | rh-ruby24-ruby-0:2.4.5-91.el7 | Fixed | RHSA-2018:3730 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7 | rh-ruby25-ruby-0:2.5.3-6.el7 | Fixed | RHSA-2018:3731 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS | rh-ruby23-ruby-0:2.3.8-69.el7 | Fixed | RHSA-2018:3729 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS | rh-ruby24-ruby-0:2.4.5-91.el7 | Fixed | RHSA-2018:3730 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS | rh-ruby25-ruby-0:2.5.3-6.el7 | Fixed | RHSA-2018:3731 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS | rh-ruby23-ruby-0:2.3.8-69.el7 | Fixed | RHSA-2018:3729 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS | rh-ruby24-ruby-0:2.4.5-91.el7 | Fixed | RHSA-2018:3730 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS | rh-ruby25-ruby-0:2.5.3-6.el7 | Fixed | RHSA-2018:3731 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS | rh-ruby23-ruby-0:2.3.8-69.el7 | Fixed | RHSA-2018:3729 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS | rh-ruby24-ruby-0:2.4.5-91.el7 | Fixed | RHSA-2018:3730 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS | rh-ruby25-ruby-0:2.5.3-6.el7 | Fixed | RHSA-2018:3731 |
| CloudForms Management Engine 5 | rh-ruby22-ruby | Affected | n/a |
| CloudForms Management Engine 5 | ruby-200-ruby | Affected | n/a |
| Red Hat Enterprise Linux 5 | ruby | Will not fix | n/a |
| Red Hat Enterprise Linux 6 | ruby | Will not fix | n/a |
| Red Hat Enterprise Linux 8 | ruby | Not affected | n/a |
| Red Hat Software Collections | rh-ruby22-ruby | Will not fix | n/a |
| Red Hat Subscription Asset Manager | ruby193-ruby | Will not fix | n/a |
No package ranges for this CVE.
Remediation
Red Hat statement
This issue affects the versions of ruby as shipped with Red Hat CloudForms 4. Red Hat Product Security has rated this issue as having security impact of Moderate. A future update may address this issue. For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/. This issue affects the versions of ruby as shipped with Red Hat Subscription Asset Manager 1. Red Hat Product Security has rated this issue as having security impact of Moderate. A future update may address this issue. For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/.
Metrics
No CVSS v4.0 score for this CVE.
No CVSS v3.1 score for this CVE.
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
1 other source (Red Hat) ▾
CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:N
AV:N/AC:L/Au:N/C:N/I:P/A:N
This CVE is not in the KEV list.
No CISA SSVC assessment for this CVE yet.
Estimated probability of exploitation in the wild in the next 30 days (FIRST EPSS). As of Oct 1, 2026.
Score over time
2021–2026- EPSS v1
- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Percentile over time
- EPSS v1
- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Table of values (42 key points)
Flat stretches are collapsed; showing up to 120 newest points.
| Date | Score | Percentile | Model |
|---|---|---|---|
| Oct 1, 2026 | 10.16% (0.10156) | 95.52th | v5 (v2026.06.15) |
| Sep 22, 2026 | 10.16% (0.10156) | 95.44th | v5 (v2026.06.15) |
| Sep 21, 2026 | 8.83% (0.08827) | 95.02th | v5 (v2026.06.15) |
| Sep 20, 2026 | 10.16% (0.10156) | 95.44th | v5 (v2026.06.15) |
| Sep 6, 2026 | 10.35% (0.10345) | 95.40th | v5 (v2026.06.15) |
| Sep 5, 2026 | 8.88% (0.08884) | 94.93th | v5 (v2026.06.15) |
| Aug 30, 2026 | 10.35% (0.10345) | 95.38th | v5 (v2026.06.15) |
| Aug 28, 2026 | 8.88% (0.08884) | 94.90th | v5 (v2026.06.15) |
| Aug 24, 2026 | 10.35% (0.10345) | 95.35th | v5 (v2026.06.15) |
| Aug 23, 2026 | 8.88% (0.08884) | 94.88th | v5 (v2026.06.15) |
| Jun 15, 2026 | 10.55% (0.10552) | 95.18th | v5 (v2026.06.15) |
| Mar 4, 2026 | 2.37% (0.02372) | 84.69th | v4 (v2025.03.14) |
| Mar 1, 2026 | 4.81% (0.04812) | 89.35th | v4 (v2025.03.14) |
| Feb 4, 2026 | 2.37% (0.02372) | 84.60th | v4 (v2025.03.14) |
| Feb 1, 2026 | 4.81% (0.04812) | 89.28th | v4 (v2025.03.14) |
| Jan 4, 2026 | 2.37% (0.02372) | 84.52th | v4 (v2025.03.14) |
| Jan 1, 2026 | 4.81% (0.04812) | 89.22th | v4 (v2025.03.14) |
| Dec 4, 2025 | 2.37% (0.02372) | 84.45th | v4 (v2025.03.14) |
| Dec 1, 2025 | 4.81% (0.04812) | 89.14th | v4 (v2025.03.14) |
| Nov 4, 2025 | 2.37% (0.02372) | 84.41th | v4 (v2025.03.14) |
| Nov 1, 2025 | 4.81% (0.04812) | 89.05th | v4 (v2025.03.14) |
| Oct 4, 2025 | 2.37% (0.02372) | 84.38th | v4 (v2025.03.14) |
| Oct 1, 2025 | 4.81% (0.04812) | 89.09th | v4 (v2025.03.14) |
| Aug 4, 2025 | 2.53% (0.02534) | 84.85th | v4 (v2025.03.14) |
| Aug 1, 2025 | 4.20% (0.04201) | 88.38th | v4 (v2025.03.14) |
| Mar 30, 2025 | 1.96% (0.01956) | 81.85th | v4 (v2025.03.14) |
| Mar 29, 2025 | 4.28% (0.04276) | 81.04th | v4 (v2025.03.14) |
| Mar 17, 2025 | 1.96% (0.01956) | 82.28th | v4 (v2025.03.14) |
| Dec 12, 2024 | 0.22% (0.00223) | 61.49th | v3 (v2023.03.01) |
| May 29, 2024 | 0.22% (0.00220) | 59.92th | v3 (v2023.03.01) |
| Apr 18, 2024 | 0.19% (0.00195) | 56.86th | v3 (v2023.03.01) |
| Feb 8, 2024 | 0.28% (0.00278) | 67.35th | v3 (v2023.03.01) |
| Aug 25, 2023 | 0.28% (0.00278) | 64.21th | v3 (v2023.03.01) |
| Mar 28, 2023 | 0.29% (0.00292) | 64.28th | v3 (v2023.03.01) |
| Mar 7, 2023 | 0.26% (0.00258) | 61.77th | v3 (v2023.03.01) |
| Mar 6, 2023 | 2.69% (0.02686) | 82.85th | v2 (v2022.01.01) |
| Apr 1, 2022 | 2.69% (0.02686) | 81.17th | v2 (v2022.01.01) |
| Feb 4, 2022 | 2.69% (0.02686) | 62.66th | v2 (v2022.01.01) |
| Feb 3, 2022 | 3.68% (0.03679) | 72.20th | v1 |
| Jan 6, 2022 | 3.68% (0.03679) | 71.95th | v1 |
| Sep 1, 2021 | 3.68% (0.03679) | 82.80th | v1 |
| Apr 14, 2021 | 3.68% (0.03679) | 0.00th | v1 |
References (21)
- http://lists.opensuse.org/opensuse-security-announce/2019-07/msg00036.html vendor-advisoryx_refsource_SUSE
- http://www.securityfocus.com/bid/103686 vdb-entryx_refsource_BIDThird Party AdvisoryVDB Entry
- http://www.securitytracker.com/id/1042004 vdb-entryx_refsource_SECTRACKThird Party AdvisoryVDB Entry
- https://access.redhat.com/errata/RHSA-2018:3729 vendor-advisoryx_refsource_REDHATThird Party Advisory
- https://access.redhat.com/errata/RHSA-2018:3730 vendor-advisoryx_refsource_REDHATThird Party Advisory
- https://access.redhat.com/errata/RHSA-2018:3731 vendor-advisoryx_refsource_REDHATThird Party Advisory
- https://access.redhat.com/errata/RHSA-2019:2028 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/security/cve/CVE-2018-6914 Vendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=1561947 Issue Tracking
- https://lists.debian.org/debian-lts-announce/2018/04/msg00023.html mailing-listx_refsource_MLISTThird Party Advisory
- https://lists.debian.org/debian-lts-announce/2018/04/msg00024.html mailing-listx_refsource_MLISTMailing ListThird Party Advisory
- https://lists.debian.org/debian-lts-announce/2018/07/msg00012.html mailing-listx_refsource_MLISTMailing ListThird Party Advisory
- https://nvd.nist.gov/vuln/detail/CVE-2018-6914
- https://usn.ubuntu.com/3626-1/ vendor-advisoryx_refsource_UBUNTUThird Party Advisory
- https://www.cve.org/CVERecord?id=CVE-2018-6914
- https://www.debian.org/security/2018/dsa-4259 vendor-advisoryx_refsource_DEBIANThird Party Advisory
- https://www.ruby-lang.org/en/news/2018/03/28/ruby-2-2-10-released/ x_refsource_CONFIRMPatchRelease Notes
- https://www.ruby-lang.org/en/news/2018/03/28/ruby-2-3-7-released/ x_refsource_CONFIRMPatchRelease Notes
- https://www.ruby-lang.org/en/news/2018/03/28/ruby-2-4-4-released/ x_refsource_CONFIRMPatchRelease Notes
- https://www.ruby-lang.org/en/news/2018/03/28/ruby-2-5-1-released/ x_refsource_CONFIRMPatchRelease Notes
- https://www.ruby-lang.org/en/news/2018/03/28/unintentional-file-and-directory-creation-with-directory-traversal-cve-2018-6914/ x_refsource_CONFIRMVendor Advisory
Change history (0)
No recorded changes yet.