A single Kubeshark MCP pod_regex argument can redirect container images and seize a Kubernetes cluster
A single injected argument to Kubeshark's MCP tool can redirect worker images to an attacker's registry, giving that attacker node and cluster-admin control of a Kubernetes cluster. GitHub's advisory credits researcher novice-22 (Urim) with privately disclosing the flaw.
- Affected
- kubeshark/kubeshark >= 53.1.0, < 53.4.0; github.com/kubeshark/kubeshark >= 0.0.2-0.20260206182249-0bbbb473ea3f, < 0.0.2-0.20260812200004-a76a1920dc75
- Fixed
- kubeshark/kubeshark 53.4.0; github.com/kubeshark/kubeshark 0.0.2-0.20260812200004-a76a1920dc75
The Kubeshark start_kubeshark MCP tool builds a kubeshark tap command by appending caller-supplied pod_regex as a bare positional argument, with no -- end-of-options separator. A value beginning with --set is parsed as a Helm flag override instead of a regex. start_kubeshark exists only when kubeshark mcp is launched with the explicit, non-default --allow-destructive flag, and the host must already hold a kubeconfig able to deploy the privileged DaemonSet.
Affected releases are kubeshark 53.1.0 through 53.3.0; version 53.4.0 fixes the flaw by appending pod_regex after a literal -- separator so it remains a positional argument. Kubeshark's workarounds are to avoid --allow-destructive unless required, restrict the host kubeconfig's permissions, and keep the MCP server away from untrusted content and agent inputs.
Sources & technical scope 2 sources
GitHub Advisory Database — original source ↗
GitHub_M CNA / CVE Program — original source ↗
Affected: kubeshark/kubeshark >= 53.1.0, < 53.4.0; github.com/kubeshark/kubeshark >= 0.0.2-0.20260206182249-0bbbb473ea3f, < 0.0.2-0.20260812200004-a76a1920dc75
Fixed: kubeshark/kubeshark 53.4.0; github.com/kubeshark/kubeshark 0.0.2-0.20260812200004-a76a1920dc75
Exploitation: No known exploitation reported in the supplied evidence; exploitation requires kubeshark mcp --allow-destructive and an authorized host kubeconfig able to deploy the privileged DaemonSet.
Scope & limitations: Individual versions tested and KEV/catalog exploitation status are not established by the supplied evidence.
External findings belong to the credited researchers.