Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. fs-git
  4. ›
  5. GMS-2017-185

GMS-2017-185: Command Injection

August 29, 2017

The fs-git module relies on child_process.exec, however, the buildCommand method used to construct exec strings does not properly sanitize data and is vulnerable to command injection across all methods that use it and call exec.

References

  • github.com/vvakame/fs-git/commit/eb5f70efa5cfbff1ab299fa7daaa5de549243998

Code Behaviors & Features

Detect and mitigate GMS-2017-185 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions up to 1.0.1

Fixed versions

  • 1.0.2

Solution

Update to version 1.0.2 or later. In lieu of updating, before passing any untrusted data to the buildCommand function, ensure that the data is sanitized using a proper shell escaping library.

Source file

npm/fs-git/GMS-2017-185.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:16:51 +0000.