gfc@2.0.1 vulnerabilities

Simple way to initialize a new git repository in an empty directory, add a file and do a first commit (or skip that part in a directory with files). Useful for unit tests and generators.

  • latest version

    2.0.2

  • first published

    8 years ago

  • latest version published

    7 years ago

  • licenses detected

  • Direct Vulnerabilities

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

    Fix vulnerabilities automatically

    Snyk's AI Trust Platform automatically finds the best upgrade path and integrates with your development workflows. Secure your code at zero cost.

    Fix for free
    VulnerabilityVulnerable Version
    • C
    Command Injection

    gfc is a Simple way to initialize a new git repository in an empty directory, add a file and do a first commit (or skip that part in a directory with files). Useful for unit tests and generators.

    Affected versions of this package are vulnerable to Command Injection via the options argument which is used to build the command that is passed to the child_process.exec function without any sanitization.

    POC

    const firstCommit = require('gfc');
    const options = {message: '""; touch HACKED;'};
    firstCommit('.', options, function(err) {});
    

    How to fix Command Injection?

    There is no fixed version for gfc.

    *