Command injection in simple-git
High severity
GitHub Reviewed
Published
Mar 12, 2022
to the GitHub Advisory Database
•
Updated Jan 27, 2023
Description
Published by the National Vulnerability Database
Mar 11, 2022
Published to the GitHub Advisory Database
Mar 12, 2022
Reviewed
Mar 14, 2022
Last updated
Jan 27, 2023
The package simple-git before 3.3.0 is vulnerable to Command Injection via argument injection. When calling the .fetch(remote, branch, handlerFn) function, both the remote and branch parameters are passed to the git fetch subcommand. By injecting some git options, it was possible to get arbitrary command execution.
References