Skip to main content

Improper Neutralization of Special Elements used in a Command ('Command Injection')

CVE-2026-42271

Severity High
Score 8.7/10

Summary

Two endpoints used to preview an MCP server before saving it -- `POST /mcp-rest/test/connection` and `POST /mcp-rest/test/tools/list` -- accepted a full server configuration in the request body, including the `command`, `args`, and `env` fields used by the stdio transport. When called with a stdio configuration, the endpoints attempted to connect, which spawned the supplied command as a subprocess on the proxy host with the privileges of the proxy process. Affected versions are from 1.74.2 prior to 1.83.7.

  • LOW
  • NETWORK
  • HIGH
  • UNCHANGED
  • NONE
  • LOW
  • HIGH
  • HIGH

CWE-77 - Command Injection

A command injection attack involves injecting an operating system command through the data input, which gets executed on the host operating system with the privileges of the victimized application. The impact of a command injection attack may range from loss of data confidentiality and integrity to unauthorized remote access to the hosting system. The attack may cause serious data breaches and system takeover.

References

Advisory Timeline

  • Published