CVE-2011-3871 Puppet uses predictable filenames, allowing arbitrary file overwrite

Medium 6.2 Published Updated

Local attackers can exploit predictable file names in Puppet edit mode to execute arbitrary code or modify files, requiring user interaction.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2011-3871?

CVE-2011-3871 is a medium-severity path traversal vulnerability in n/a, published on 27 Oct 2011. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

Official description

Puppet 2.7.x before 2.7.5, 2.6.x before 2.6.11, and 0.25.x, when running in --edit mode, uses a predictable file name, which allows local users to run arbitrary Puppet code or trick a user into editing arbitrary files.

Weakness: CWE-264

Which versions are affected by CVE-2011-3871?

4 open source packages ship an affected version, including puppet. It affects 2 products.

PackageAffectedFixed in
puppet RubyGemsAll versions2.6.11
puppet RubyGemsAll versions2.6.11
puppet RubyGemsFrom 2.7.02.7.5
puppet RubyGemsFrom 2.7.02.7.5

Products include Puppet Puppet, Puppetlabs Puppet.

How do I fix CVE-2011-3871?

Upgrade puppet to a fixed version for your release line: 2.6.11 or 2.7.5.

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

Is CVE-2011-3871 being exploited?

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

Sources

Also known as DEBIAN-CVE-2011-3871, GHSA-mpmx-gm5v-q789.

Is CVE-2011-3871 in your software?

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

Check your SBOMs for free