tomato command injection in /api/exec endpoint

Severity: info · CVSS 9 · Published 2020-09-02

tomato is a Node.js module used for executing commands. A command injection vulnerability in the /api/exec endpoint allows attackers to execute arbitrary system commands without validation. This could lead to complete system compromise, data theft, or unauthorized service disruption.

Vendors: npm.

Quick answers

Is This vulnerability exploited in the wild?
No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.
How severe is This vulnerability?
Informational severity, with a CVSS score of 9, published 2 September 2020.
Which products and versions are affected?
tomato (npm) SEMVER:introduced=0.
Is there a fix for This vulnerability?
No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.
How is This vulnerability attacked?
It is attacked over the network, in a software library.
Am I affected?
Check whether you run tomato (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

The vulnerability is a command injection flaw (CWE-77) in the /api/exec endpoint of tomato. The endpoint fails to validate or sanitize user input before passing it to system command execution functions. An attacker can send crafted input containing shell metacharacters or command separators to execute arbitrary commands with the privileges of the process running tomato. No authentication or special preconditions are mentioned, suggesting the endpoint is likely network-accessible. No fix is currently available as of the advisory publication date.

Affected products

  • npm tomato all versions

Timeline

  • 2020-09-02: disclosed

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.