Arbitrary Code Execution Affecting bundler package, versions <2.0


Severity

Recommended
0.0
critical
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.47% (76th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Arbitrary Code Execution vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-RUBY-BUNDLER-20285
  • published13 Feb 2017
  • disclosed4 Oct 2016
  • creditSteve Richert

Introduced: 4 Oct 2016

CVE-2016-7954  (opens in a new tab)
CWE-94  (opens in a new tab)

Overview

bundler is a dependencies manager. Affected versions of this Gem contain a flaw that is triggered when handling a Gemfile that contains multiple top-level source lines. This may allow a gem to be installed from an unintended source server, allowing an attacker to install specially crafted gems, leading to arbitrary code execution.

This bug was thought to be fixed in Bundler 1.7 here.

Details

Bundler allows the user to specify sources from which Ruby gems are installed. If a secondary source is specified, even if scoped to a specific gem, that source is silently applied to all declared gems. This allows an attacker to introduce arbitrary code into an application via gem name collision on the secondary source, which will unexpectedly (and without warning) take priority over the primary source.

CVSS Scores

version 3.1