CVE-2017-8418 RuboCop gem Insecure use of /tmp

Low 3.3 Published Updated

Local attackers can tamper with cache files of other users due to unsafe temporary file handling in RuboCop.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2017-8418?

CVE-2017-8418 is a low-severity path traversal vulnerability in n/a, published on 2 May 2017. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

RuboCop 0.48.1 and earlier does not use /tmp in safe way, allowing local users to exploit this to tamper with cache files belonging to other users.

Weakness: CWE-668

Which versions are affected by CVE-2017-8418?

2 open source packages ship an affected version, including rubocop. It affects 1 product.

PackageAffectedFixed in
rubocop RubyGemsAll versions0.49.0
rubocop RubyGemsAll versions0.49.0

Products include Rubocop Project Rubocop.

How do I fix CVE-2017-8418?

Upgrade rubocop to 0.49.0 or later.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2017-8418 being exploited?

There is no known exploitation of CVE-2017-8418 in the wild and no public exploit code.

Sources

Also known as DEBIAN-CVE-2017-8418, GHSA-wmjf-jpjj-9f3j.

Is CVE-2017-8418 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free