CVE-2026-55157: CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') in ooples token-optimizer-mcp
Token Optimizer MCP measures token savings per AI coding agent, optimizes context, and shares a live local knowledge graph across 16 CLI clients. Prior to version 5.1.0, token-optimizer-mcp is vulnerable to OS command injection in the smart_user tool. Any MCP client that can call the smart_user tool can execute arbitrary shell commands through the username argument of the get-user-info operation. The commands execute with the privileges of the user running the token-optimizer-mcp server. This issue has been patched in version 5.1.0.
AI Analysis
Technical Summary
The token-optimizer-mcp package (tested in v5.0.1) has an OS command injection vulnerability (CWE-78) in the smart_user tool. The get-user-info operation accepts a username parameter that is directly interpolated into a shell command string executed by execAsync(). Although the username is wrapped in double quotes, POSIX shells still evaluate command substitution such as $(...) and backticks inside double quotes. An attacker can supply a crafted username containing command substitution to execute arbitrary commands on the host with the MCP server's user privileges. A proof-of-concept demonstrates writing the output of the id command to a file under /tmp, confirming command execution. The vulnerability affects versions prior to 5.1.0.
Potential Impact
An attacker able to invoke the smart_user tool's get-user-info operation with a controlled username can execute arbitrary OS commands on the MCP server with the privileges of the user running the MCP server process. This can lead to full compromise of the server environment depending on the MCP server user's privileges. The CVSS 3.1 score is 8.4 (high), reflecting high confidentiality, integrity, and availability impact.
Mitigation Recommendations
A patch is available for this vulnerability. Users should upgrade token-optimizer-mcp to version 5.1.0 or later where this issue is fixed. Until patched, avoid exposing the smart_user tool's get-user-info operation to untrusted clients or inputs. The vendor advisory confirms a fix is available; apply the official update to remediate.
CVE-2026-55157: CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') in ooples token-optimizer-mcp
Description
Token Optimizer MCP measures token savings per AI coding agent, optimizes context, and shares a live local knowledge graph across 16 CLI clients. Prior to version 5.1.0, token-optimizer-mcp is vulnerable to OS command injection in the smart_user tool. Any MCP client that can call the smart_user tool can execute arbitrary shell commands through the username argument of the get-user-info operation. The commands execute with the privileges of the user running the token-optimizer-mcp server. This issue has been patched in version 5.1.0.
CVSS v3.1
Score 8.4high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The token-optimizer-mcp package (tested in v5.0.1) has an OS command injection vulnerability (CWE-78) in the smart_user tool. The get-user-info operation accepts a username parameter that is directly interpolated into a shell command string executed by execAsync(). Although the username is wrapped in double quotes, POSIX shells still evaluate command substitution such as $(...) and backticks inside double quotes. An attacker can supply a crafted username containing command substitution to execute arbitrary commands on the host with the MCP server's user privileges. A proof-of-concept demonstrates writing the output of the id command to a file under /tmp, confirming command execution. The vulnerability affects versions prior to 5.1.0.
Potential Impact
An attacker able to invoke the smart_user tool's get-user-info operation with a controlled username can execute arbitrary OS commands on the MCP server with the privileges of the user running the MCP server process. This can lead to full compromise of the server environment depending on the MCP server user's privileges. The CVSS 3.1 score is 8.4 (high), reflecting high confidentiality, integrity, and availability impact.
Mitigation Recommendations
A patch is available for this vulnerability. Users should upgrade token-optimizer-mcp to version 5.1.0 or later where this issue is fixed. Until patched, avoid exposing the smart_user tool's get-user-info operation to untrusted clients or inputs. The vendor advisory confirms a fix is available; apply the official update to remediate.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-49mq-fc6q-3h46
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2026-55157"]
- Ecosystems
- ["npm"]
- Database Specific Severity
- HIGH
- Cvss Version
- 3.1
Threat ID: 6a7ff5ecbf8831d53987eba2
Added to database: 08/15/2026, 05:15:24 UTC
Last enriched: 09/29/2026, 01:58:46 UTC
Last updated: 09/30/2026, 07:04:49 UTC
Views: 61
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.