CVE-2025-53355: Command Injection Vulnerability in mcp-server-kubernetes

mcp-server-kubernetes Updated 02 Oct 2025

Summary

08/07/2025
Yes i
High
7.5

CVE-2025-53355: MCP Server Kubernetes vulnerable to command injection in several tools. Affects mcp-server-kubernetes versions < 2.5.0. Fixed in 2.5.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

Background

mcp-server-kubernetes is an open-source tool designed to facilitate Kubernetes operations through a command-line interface. It provides functionalities such as scaling deployments, patching resources, and explaining Kubernetes resources. However, due to its reliance on user input for command execution, it is susceptible to command injection vulnerabilities, which can lead to severe security risks.

Vulnerability Detail

The vulnerability arises from the unsanitized use of user input in the child_process.execSync function, allowing attackers to inject arbitrary system commands. This can lead to remote code execution under the privileges of the server process. The specific tools affected include kubectl_scale, kubectl_patch, and others that execute shell commands based on user input. Attackers can exploit this vulnerability through indirect prompt injection, where malicious commands are embedded in log messages or user prompts, leading to unintended command execution.

How To Fix

Latest published version: 4.1.9 as of 23 Oct 2026

npm install mcp-server-kubernetes@4.1.9

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

2.5.0

This is the first release that contains the fix.

npm install mcp-server-kubernetes@2.5.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, avoid using child_process.execSync with untrusted input. Instead, consider using child_process.execFileSync, which allows you to pass command arguments as a separate array, thus preventing shell interpretation. For example:

const { execFileSync } = require('child_process');
const command = 'kubectl';
const args = ['scale', 'deployment', input.name, '--replicas', input.replicas, '--namespace', namespace];
const result = execFileSync(command, args, { encoding: 'utf8' });

Conclusion

The command injection vulnerability in mcp-server-kubernetes (CVE-2025-53355) poses significant security risks due to its potential for remote code execution. It is crucial for users to update to the patched version 2.5.0 or later and to consider implementing workarounds to mitigate risks until an update can be applied.

See every vulnerability recorded for mcp-server-kubernetes →

Share this vulnerability

FAQ

CVE-2025-53355 is a command injection vulnerability found in the mcp-server-kubernetes package, allowing attackers to execute arbitrary commands on the server.

You can check if your application is affected by using Vulert, which monitors vulnerabilities in open-source packages. Visit Vulert Scanner to test your application without any signup.

The vulnerability can lead to remote code execution, allowing attackers to execute commands with the server's privileges, potentially compromising the entire system.

You can update the package to the patched version by running the command: npm install mcp-server-kubernetes@2.5.0.

If an immediate update is not possible, implement the workaround by using execFileSync instead of execSync to avoid command injection risks.

Related vulnerabilities

Recent vulnerabilities recorded for mcp-server-kubernetes.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

How To Fix

Latest published version: 4.1.9 as of 23 Oct 2026

npm install mcp-server-kubernetes@4.1.9

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

2.5.0

This is the first release that contains the fix.

npm install mcp-server-kubernetes@2.5.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback