rubygems-update is vulnerable to Path Traversal
53
Medium Risk
Gem::Source#fetch_spec builds the on-disk spec cache path directly from the spec name in a name tuple returned by a remote gem index, without validating that name as a path component. A crafted spec name containing path separators or .. causes the downloaded gemspec bytes to be written outside Gem.spec_cache_dir, before the Marshal payload is ever loaded. A malicious or compromised gem source can therefore trigger an arbitrary file write on the client with an attacker-controlled path and content. The fix rejects any spec name whose File.basename differs from the full value before the cache path is constructed.
You are affected if you are using a version that falls within the vulnerable range and fetch specs from an untrusted or compromised gem source.
rubygems-update is vulnerable to Path Traversal in versions 2.0.0 - 4.0.16.
Upgrade the rubygems-update library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant