A vulnerability has been found in wonderwhy-er DesktopCommanderMCP up to 0.2.13. The affected element is the function extractBaseCommand of the file src/command-manager.ts of the component Absolute Path Handler. Such manipulation leads to os command injection. The attack may be performed from remote. The exploit has been disclosed to the public and may be used. The vendor explains: The usual use case is that AI is asked to do something, picks commands itself, and typically uses simple command names without absolute paths. Its curious why a user would ask the model to bypass restrictions this way. (…) This could potentially be a problem, but we are yet to hear reports of this being an issue in actual workflows. Well leave this issue open for situations where people may report this as a problem for the long term.
The product constructs all or part of a command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended command when it is sent to a downstream component.
Many protocols and products have their own custom command language. While OS or shell command strings are frequently discovered and targeted, developers may not realize that these other command languages might also be vulnerable to attacks.