mcp-kubernetes-server has a Command Injection vulnerability
Moderate severity
GitHub Reviewed
Published
Sep 15, 2025
to the GitHub Advisory Database
•
Updated Sep 25, 2025
Description
Published by the National Vulnerability Database
Sep 15, 2025
Published to the GitHub Advisory Database
Sep 15, 2025
Reviewed
Sep 15, 2025
Last updated
Sep 25, 2025
mcp-kubernetes-server
does not correctly enforce the--disable-write
/--disable-delete
protections when commands are chained. The server only inspects the first token to decide whether an operation is write/delete, which allows a read-like command to be followed by a write action using shell metacharacters (e.g.,kubectl version; kubectl delete pod <name>
). A remote attacker who can invoke the server may therefore bypass the intended write/delete restrictions and perform state-changing operations against the Kubernetes cluster.Affected versions: through
0.1.11
(no patched release available as of now).Mitigations:
--disable-kubectl
and/or--disable-helm
to fully block those execution paths.References