Command Injection Affecting mversion package, versions <2.0.1


Severity

Recommended
0.0
high
0
10

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

Threat Intelligence

Exploit Maturity
Proof of concept
EPSS
0.36% (72nd 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 Command Injection vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-JS-MVERSION-573174
  • published25 Jun 2020
  • disclosed24 Jun 2020
  • creditHabib Ullah

Introduced: 24 Jun 2020

CVE-2020-7688  (opens in a new tab)
CWE-78  (opens in a new tab)
First added by Snyk

How to fix?

Upgrade mversion to version 2.0.1 or higher.

Overview

mversion is a cross packaging manager module version handler/bumper.

Affected versions of this package are vulnerable to Command Injection. The issue occurs because tagName user input is formatted inside the exec function is executed without any checks.

PoC:

var mversion = require('mversion');

mversion.update({ version: "major", commitMessage: "testing", tagName: "; touch hbkhan", })

CVSS Scores

version 3.1