cbcvebase.
CVE-2017-0901
published 2017-08-31

CVE-2017-0901: RubyGems version 2.6.12 and earlier fails to validate specification names, allowing a maliciously crafted gem to potentially overwrite any file on the…

PriorityP261high7.5CVSS 3.0
AVNACLPRNUINSUCNIHAN
EXPLOIT
EPSS
29.44%
98.0th percentile
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.

Affected

22 ranges
VendorProductVersion rangeFixed in
canonicalubuntu_linux
canonicalubuntu_linux
canonicalubuntu_linux
debiandebian_linux
debiandebian_linux
debianrubygems< rubygems 3.2.0~rc.1-1 (bookworm)rubygems 3.2.0~rc.1-1 (bookworm)
hackeronerubygems
redhatenterprise_linux_desktop
redhatenterprise_linux_server
redhatenterprise_linux_server_aus
redhatenterprise_linux_server_aus
redhatenterprise_linux_server_eus
redhatenterprise_linux_server_eus
redhatenterprise_linux_server_eus
redhatenterprise_linux_server_tus
redhatenterprise_linux_server_tus
redhatenterprise_linux_workstation
rubygemsrubygems<= 2.6.12
rubygemsrubygems>= 0 < 3.2.0~rc.1-13.2.0~rc.1-1
rubygemsrubygems>= 0 < 3.2.0~rc.1-13.2.0~rc.1-1
rubygemsrubygems>= 0 < 3.2.0~rc.1-13.2.0~rc.1-1
rubygemsrubygems>= 0 < 3.2.0~rc.1-13.2.0~rc.1-1

Detection & IOCsextracted from sources · hover to see the quote

filenamereplace-rackup.gem
filenamesrc.tar.gz
urlhttps://gitlab.com/exploit-database/exploitdb-bin-sploits/-/raw/main/bin-sploits/42611.zip
path../gems/rack
pathgems/rack-2.0.3/bin/rackup
  • Detect gem installations where the gem specification name field contains path traversal sequences (e.g., '../') which would allow files to be written outside the intended gem installation directory.
  • Monitor for unexpected file modifications in gem bin directories or system directories (e.g., /etc/dbus-1/) following execution of 'gem install' commands, which may indicate exploitation of the path traversal via malicious gem name.
  • Flag 'gem install' invocations against local .gem files (not from rubygems.org) especially with --no-doc flag, as the PoC exploit uses a locally crafted gem file.
  • ·The vulnerability exists in RubyGems version 2.6.12 and earlier; the fix was introduced in version 2.6.13. Environments running affected versions should be prioritized for detection.
  • ·The exploit is local in scope — the attacker must be able to run 'gem install' on the target system with a crafted .gem file.
  • ·Red Hat Enterprise Linux 6 rubygems package was marked 'Will not fix', meaning systems running RHEL 6 may remain permanently vulnerable and require compensating controls.

CVSS provenance

nvdv3.07.5HIGHCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
nvdv2.06.4MEDIUMAV:N/AC:L/Au:N/C:N/I:P/A:P
osv9.1CRITICAL
vendor_ubuntu9.1CRITICAL
vendor_debian7.5HIGH
vendor_redhat7.5HIGH
CVEs like this are exactly what “Exploited This Week” covers.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.