Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remote Command Execution in mversion #56

Closed
Hbkhan opened this issue Jun 24, 2020 · 2 comments · Fixed by #57
Closed

Remote Command Execution in mversion #56

Hbkhan opened this issue Jun 24, 2020 · 2 comments · Fixed by #57

Comments

@Hbkhan
Copy link

Hbkhan commented Jun 24, 2020

✍️ Description

Affected versions allow an attacker to execute remote commands. The issue occurs because tagName user input is formatted inside the exec function in #L64 is executed without any checks.

🕵️‍♂️ Proof of Concept

// poc.js
// node poc.js

var mversion = require('mversion');

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

💥 Impact

This issue may lead to remote code execution if a client of the library calls the vulnerable method with untrusted input.

@Hbkhan
Copy link
Author

Hbkhan commented Jun 24, 2020

@mikaelbr Can you request CVE for this?

@Hbkhan
Copy link
Author

Hbkhan commented Jun 25, 2020

@mikaelbr CVE ID: CVE-2020-7688

It will get populated once the fixed version (2.0.1) will be released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant