CVE-2017-0901: Input Validation

Published Aug 31, 2017
·
Updated

RubyGems version 2.6.12 and earlier fails to validate specification names, allowing a maliciously crafted gem to potentially overwrite any file on the filesystem.

Upstream patch:

https://github.com/rubygems/rubygems/commit/ad5c0a53a86ca5b218c7976765c0365b91d22cb2

Bug report:

https://hackerone.com/reports/243156

External References:

http://blog.rubygems.org/2017/08/27/2.6.13-released.html

Affected Software

48 affected componentsFixes available
redhat/rubygems<2.6.13
2.6.13
redhat/ruby<2.4.2
2.4.2
redhat/ruby<2.2.8
2.2.8
redhat/ruby<2.3.5
2.3.5
Rubygems RubyGems<=2.6.12
Debian Debian Linux=8.0
Debian Debian Linux=9.0
Canonical Ubuntu Linux=14.04
Canonical Ubuntu Linux=16.04
Canonical Ubuntu Linux=17.10
redhat Enterprise Linux Desktop=7.0
redhat Enterprise Linux Server=7.0
redhat Enterprise Linux Server Aus=7.4
redhat Enterprise Linux Server Aus=7.6
redhat Enterprise Linux Server Eus=7.4
redhat Enterprise Linux Server Eus=7.5
redhat Enterprise Linux Server Eus=7.6
redhat Enterprise Linux Server Tus=7.4
redhat Enterprise Linux Server Tus=7.6
redhat Enterprise Linux Workstation=7.0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.2.8-r0
2.2.8-r0
alpine/ruby<2.3.5-r0
2.3.5-r0
alpine/ruby<2.3.5-r0
2.3.5-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby<2.4.2-r0
2.4.2-r0
alpine/ruby2.2<2.2.8-r0
2.2.8-r0
alpine/ruby2.2<2.2.8-r0
2.2.8-r0
debian/rubygems
1.8.24-1+deb7u13.2.0~rc.1-1
debian/ruby1.9.1
1.9.3.194-8.1+deb7u6
debian/ruby2.1
2.1.5-2+deb8u4
debian/ruby2.3
2.3.3-1+deb9u1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/rubygems to a version that resolves this vulnerability.

    Fixed in 2.6.13
  2. Upgrade

    Upgrade redhat/ruby to a version that resolves this vulnerability.

    Fixed in 2.4.2
  3. Upgrade

    Upgrade redhat/ruby to a version that resolves this vulnerability.

    Fixed in 2.2.8
  4. Upgrade

    Upgrade redhat/ruby to a version that resolves this vulnerability.

    Fixed in 2.3.5
  5. Upgrade

    Upgrade alpine/ruby to a version that resolves this vulnerability.

    Fixed in 2.4.2-r0
  6. Upgrade

    Upgrade alpine/ruby to a version that resolves this vulnerability.

    Fixed in 2.2.8-r0
  7. Upgrade

    Upgrade alpine/ruby to a version that resolves this vulnerability.

    Fixed in 2.3.5-r0
  8. Upgrade

    Upgrade alpine/ruby2.2 to a version that resolves this vulnerability.

    Fixed in 2.2.8-r0
  9. Upgrade

    Upgrade debian/rubygems to a version that resolves this vulnerability.

    Fixed in 1.8.24-1+deb7u1Fixed in 3.2.0~rc.1-1
  10. Upgrade

    Upgrade debian/ruby1.9.1 to a version that resolves this vulnerability.

    Fixed in 1.9.3.194-8.1+deb7u6
  11. Upgrade

    Upgrade debian/ruby2.1 to a version that resolves this vulnerability.

    Fixed in 2.1.5-2+deb8u4
  12. Upgrade

    Upgrade debian/ruby2.3 to a version that resolves this vulnerability.

    Fixed in 2.3.3-1+deb9u1
  13. Upgrade

    Upgrade rubygems/rubygems to a version that resolves this vulnerability.

    Fixed in 2.6.13

Event History

Aug 27, 2017
CVE Published
via MITRE·12:00 AM
Data Sourced
via MITRE·12:00 AM
DescriptionWeakness
Aug 31, 2017
Data Sourced
12:00 AM
RemedyDescriptionSeverityAffected Software
Updated
via Ubuntu·12:00 AM
RemedyDescriptionAffected Software
Updated
via Ubuntu·12:00 AM
Description
CVE Published
via MITRE·08:00 PM
Data Sourced
via OSV·08:29 PM
DescriptionSeverityAffected Software
Oct 9, 2019
Data Sourced
11:21 PM
Weakness
Data Sourced
via NVD·11:21 PM
RemedyDescriptionSeverityWeaknessAffected Software
Updated
11:21 PM
Affected Software
Mar 11, 2021
Data Sourced
via Red Hat·03:41 PM
DescriptionSeverityAffected Software
Nov 21, 2024
Updated
via NVD·03:03 AM
RemedyAffected Software
Apr 20, 2025
Updated
via NVD·01:37 AM
Affected Software
Jul 11, 2025
Updated
via Ubuntu·12:00 AM
Description
Jun 17, 2026
Updated
via NVD·12:58 AM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Peer vulnerabilities

Found alongside the following vulnerabilities.

Frequently Asked Questions

1

What is the vulnerability ID?

The vulnerability ID is CVE-2017-0901.

2

What is the severity of CVE-2017-0901?

The severity of CVE-2017-0901 is high, with a severity value of 7.5.

3

How does CVE-2017-0901 affect RubyGems?

CVE-2017-0901 affects RubyGems version 2.6.12 and earlier.

4

What is the impact of CVE-2017-0901?

CVE-2017-0901 allows a maliciously crafted gem to potentially overwrite any file on the filesystem.

5

How can I fix CVE-2017-0901?

To fix CVE-2017-0901, update RubyGems to version 2.6.13 or later.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203