Vulnerability  ·  2026-10-31

DBHub MCP server: read-only SQL validation bypass on MySQL/MariaDB connectors (comment-smuggling)

VulnerabilityMedium impactGlobalCVE-2026-61789
DBHub's SQL parser misclassifies double-dash as a comment start, so the read-only validation can be bypassed on the MySQL/MariaDB connectors, letting a client issue writes that should have been blocked.
DBHub is an MCP server that gives AI agents database access. A bypassable read-only guard means a prompt-injected or malicious agent can mutate production data through a connector the operator believed was read-only.
The read-only SQL validator treats every double-dash as a comment start, whereas MySQL/MariaDB do not; a client can smuggle a statement past the guard and execute writes against a connector that is supposed to be read-only.
DBHub prior to 0.22.6 — src/utils/sql-parser.ts scanSingleLineComment.
Upgrade to DBHub 0.22.6 or later (commit 872bb33); if on an affected version, keep the MySQL/MariaDB read-only connectors off untrusted agent clients.
NVD — CVE-2026-61789DBHub fix commit
See this in the live feed Explore related AI security and governance findings — updated every morning.
Open the feed →