mssql-mcp-core: SQL injection in mssql-mcp write tools via unparameterized table names and WHERE clauses
CVE-2026-63129 · GHSA-2m9m-6cr5-9x25 · published 2026-11-19
- Severity
- High
- CVSS score
- 8.8
- Chance of exploitation (EPSS)
- 0.55%
- Fixed in
- 0.6.0
An actor who can supply tool arguments (a malicious or compromised MCP client, or an LLM agent steered via indirect prompt injection) could read, modify, or drop arbitrary data, bypass the read_data allow/deny validation and the preview/confirmation/maxRows safeguards, and conditionally achieve OS command execution.
Upgrade @connorbritain/mssql-mcp-core to 0.6.0 or later, and @connorbritain/mssql-mcp-reader to 0.5.0 or later, and @connorbritain/mssql-mcp-server to 0.6.0 or later, and @connorbritain/mssql-mcp-writer to 0.5.0 or later. If you start it from an MCP config with npx or uvx, pin that version so an old cached copy is not used.
Fixed in @connorbritain/mssql-mcp-core 0.6.0: All identifiers are validated against a strict allowlist and bracket-quoted via a shared helper. The free-form whereClause string parameter is removed (breaking change) and replaced with structured, parameterized filters ({ column, operator, value }) using an operator allowlist. Values are always bound, never interpolated. list_databases validates stateFilter against a fixed allowlist before use. Upgrade the consumer packages: mssql-mcp-reader 0.5.0, mssql-mcp-writer 0.5.0, mssql-mcp-server 0.6.0 (all depend on core ^0.6.0).
Upgrading is the only complete fix; the list_databases (stateFilter) sink is reachable even under READONLY=true and in the reader package. As defense in depth, run the server under a least-privilege SQL login with xp_cmdshell disabled, and restrict which MCP clients can invoke the tools.
| Package | Registry | Affected | Fixed in |
|---|---|---|---|
| @connorbritain/mssql-mcp-core | npm | <= 0.5.0 | 0.6.0 |
| @connorbritain/mssql-mcp-reader | npm | <= 0.4.2 | 0.5.0 |
| @connorbritain/mssql-mcp-server | npm | <= 0.5.2 | 0.6.0 |
| @connorbritain/mssql-mcp-writer | npm | <= 0.4.2 | 0.5.0 |
3 registered MCP servers install an affected version today, by the dependency versions a fresh install resolves.
- io.github.ConnorBritain/mssql@connorbritain/mssql-mcp-core@0.1.5
- io.github.ConnorBritain/mssql-reader@connorbritain/mssql-mcp-core@0.1.5
- io.github.ConnorBritain/mssql-writer@connorbritain/mssql-mcp-core@0.1.5
- CriticalLiteLLM has SQL Injection in Proxy API key verificationlitellmExploited
- Criticaln8n Vulnerable to Remote Code Execution via Expression Injectionn8n, n8nExploited
- HighLiteLLM has a sandbox escape in custom-code guardraillitellmExploited
- HighLangflow affected by Remote Code Execution via validate_code() exec()langflowExploited
- CriticalJupyter MCP Server: Browser DNS rebinding can hijack the Jupyter backend through management routesjupyter-mcp-server
- Criticalmem0ai Databricks vector store vulnerable to SQL injectionmem0ai
The impact, patch and workaround text comes from the advisory, shortened (GitHub Advisory Database, CC BY 4.0). Proof-of-concept and reproduction sections and code are left out; the original advisory has them.