Quick Take
- What: SQL injection vulnerability (CVE-2026-63129, CVSS 8.8) in mssql-mcp-core, the shared library powering MSSQL MCP servers, allows AI agents to execute arbitrary T-SQL commands
- Who is affected: Users of mssql-mcp-core versions before 0.6.0, mssql-mcp-server before 0.6.0, and mssql-mcp-reader and mssql-mcp-writer before 0.5.0
- Attack vector: Malicious or compromised MCP clients, or LLM agents steered via indirect prompt injection, can supply crafted tool arguments to read, modify, or drop arbitrary data
- Bypass: Attackers can bypass preview, confirmation, and maxRows safety controls because vulnerable queries execute before these safeguards
- What to do: Upgrade to mssql-mcp-core 0.6.0, mssql-mcp-server 0.6.0, or mssql-mcp-reader and mssql-mcp-writer 0.5.0
In plain English
mssql-mcp-core is a tool that connects AI assistants to Microsoft SQL Server databases so they can read and change data. A bug let anyone who could feed the AI instructions, directly or by hiding them in documents it reads, slip their own database commands into the tool, skipping its safety checks. That could be used to read or delete data, and on badly configured servers even to run system commands. The fix is in mssql-mcp-core and mssql-mcp-server 0.6.0 and in the reader and writer packages 0.5.0.
What you should do: If you use these tools, update now; if not, you do not need to do anything.
What happened
Multiple database tools in mssql-mcp-core interpolated caller-controlled identifiers and predicates directly into T-SQL batches passed to the node-mssql Request.query() API while parameterizing only data values. The affected tools include update_data, delete_data, insert_data, execute_transaction, create_table, create_index, drop_table, and list_databases.
The update_data and delete_data tools accepted unsafe tableName and free-form whereClause input that was interpolated raw into SQL queries. The insert_data tool interpolated tableName and column names (object keys) without sanitization. The execute_transaction tool applied the same raw tableName and whereClause interpolation per operation. The create_table, create_index, and drop_table tools interpolated table, column, index, and schema identifiers with no or insufficient validation.
The list_databases tool in the reader tier interpolated the stateFilter argument raw into the query, with only a non-enforced inputSchema enum guarding it. The only check on whereClause was that it was non-empty.
Because row-count and preview queries execute before the confirmUpdate or confirmDelete step, a malicious whereClause or tableName executed on the first call, bypassing the preview, confirmation, and maxRows safety controls. The Request.query() method submits a multi-statement T-SQL batch, so a crafted input enabled stacked statements (arbitrary DDL/DML), sub-selects, and (with a privileged login and xp_cmdshell enabled) OS command execution.
An actor who can supply tool arguments, such as 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.
The vulnerability is tracked as CVE-2026-63129 with a CVSS score of 8.8 (high severity). It is classified as CWE-89 (Improper Neutralization of Special Elements used in an SQL Command).
What you should do
Upgrade to the patched versions immediately. Install mssql-mcp-core 0.6.0, mssql-mcp-server 0.6.0, or mssql-mcp-reader and mssql-mcp-writer 0.5.0. All consumer packages now 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, so no workaround provides full protection.
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.
What it means
The vulnerability demonstrates the security risks of AI agent tool frameworks that construct database queries by string interpolation rather than parameterization. The flaw allowed attackers to bypass multiple layers of safety controls (preview, confirmation, row limits) because the vulnerable queries executed before those safeguards could intervene.
The fix in version 0.6.0 validates all identifiers against a strict allowlist and bracket-quotes them via a shared helper. The free-form whereClause string parameter is removed (a breaking change) and replaced with structured, parameterized filters ({ column, operator, value }) using an operator allowlist. Values are always bound, never interpolated. The list_databases tool validates stateFilter against a fixed allowlist before use.
The vulnerability was discovered by security researchers novice-22 and m10x and disclosed through GitHub’s security advisory process.
Database MCP servers keep failing in similar ways: see our reports on the pgEdge Postgres MCP Server SQL injection and the pgEdge write confirmation bypass. New cases are tracked in our AI Security hub.
Sources
- NVD CVE-2026-63129
- GitHub Advisory GHSA-2m9m-6cr5-9×25



