Skip to main content
Vulnerability Database/CVE-2026-108604

CVE-2026-108604: Tabularis Auth Bypass Vulnerability

CVE-2026-108604 is an authentication bypass flaw in Tabularis that allows attackers to bypass read-only mode restrictions through malicious SELECT statements. This post explains its impact, affected versions, and mitigation steps.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-108604 Overview

CVE-2026-108604 is an incorrect authorization vulnerability [CWE-863] in Tabularis through version 0.27.0. The flaw resides in the Model Context Protocol (MCP) run_query safety gate that enforces read-only mode. The gate classifies statements by their leading keyword, treating any SELECT as safe. Prompt-injected agents or untrusted MCP clients can submit side-effecting SELECT statements to bypass approval prompts. Attackers can invoke PostgreSQL functions such as setval, nextval, or query_to_xml with embedded DELETE to modify data without user consent.

Critical Impact

Untrusted MCP clients or prompt-injected AI agents can write to or delete data from Tabularis-connected databases without triggering the approval workflow.

Affected Products

  • Tabularis through version 0.27.0
  • Tabularis MCP server component (src-tauri/src/mcp/mod.rs)
  • Tabularis AI activity module (src-tauri/src/ai_activity.rs)

Discovery Timeline

  • 2026-10-10 - CVE-2026-108604 published to NVD
  • 2026-10-16 - Last updated in NVD database

Technical Details for CVE-2026-108604

Vulnerability Analysis

Tabularis exposes database operations through an MCP interface used by AI assistants and other MCP clients. The run_query tool enforces a safety gate intended to require explicit user approval before any write operation executes. The gate classifies queries using a simple prefix check: statements starting with SELECT are routed as read-only, while statements starting with INSERT, UPDATE, DELETE, or DDL keywords trigger an approval prompt.

This keyword-based classification does not reflect the actual semantics of PostgreSQL. Several PostgreSQL functions and constructs permit side effects inside a SELECT statement. Calls to sequence functions such as setval(...) and nextval(...) modify sequence state. The query_to_xml function executes an arbitrary SQL string passed as its first argument, which can include a DELETE, UPDATE, or INSERT. Because the wrapping statement begins with SELECT, the safety gate approves the query without prompting the operator.

The result is a confused-deputy condition. The MCP client, which the user may not fully trust, can direct Tabularis to execute arbitrary mutations under the credentials of the connected database session.

Root Cause

The root cause is incorrect authorization logic in the run_query classification path. The implementation assumes a one-to-one mapping between the leading SQL verb and the operation's effect on data. PostgreSQL does not provide that guarantee. Safe classification requires parsing the statement, resolving function calls, and rejecting any construct capable of invoking a side-effecting routine.

Attack Vector

Exploitation requires a local attack vector and user interaction, consistent with a user operating an MCP client against their own Tabularis instance. The adversary is either a malicious or compromised MCP client, or a prompt-injection payload delivered through content the AI agent processes. The attacker crafts a SELECT wrapper that calls setval, nextval, or query_to_xml('DELETE FROM ...'). Tabularis forwards the query to PostgreSQL without an approval prompt, and the database executes the embedded mutation.

The vulnerability affects data integrity and availability. It does not directly expose confidential data beyond what the MCP session already permits.

Detect Identity Attacks the Moment Authentication Fails

Singularity™ Identity surfaces credential misuse, lateral movement, and privilege escalation in real time, so you can contain the breach before it spreads.

Stop Identity Attacks

Detection Methods for CVE-2026-108604

Indicators of Compromise

  • Database audit log entries showing calls to setval, nextval, query_to_xml, query_to_json, or dblink originating from the Tabularis session user.
  • Unexpected DELETE, UPDATE, or INSERT operations recorded with a SELECT statement in the Tabularis MCP activity log.
  • Sequence values that advance or reset without a corresponding application-level operation.

Detection Strategies

  • Enable PostgreSQL log_statement = 'all' on databases exposed to Tabularis and alert on SELECT statements that reference known side-effecting functions.
  • Correlate Tabularis MCP run_query events in ai_activity.rs logs with database write operations occurring in the same transaction window.
  • Review AI agent transcripts for prompts that instruct the assistant to run SQL wrapped in query_to_xml or sequence functions.

Monitoring Recommendations

  • Monitor the database role used by Tabularis for any write operation when the application is expected to be read-only.
  • Alert on new or unusual MCP client connections to the Tabularis server, particularly from non-interactive agents.
  • Track changes to sequence objects and compare against expected application behavior.

How to Mitigate CVE-2026-108604

Immediate Actions Required

  • Restrict the PostgreSQL role used by Tabularis to the minimum privileges required, revoking INSERT, UPDATE, DELETE, and EXECUTE on sequence functions where feasible.
  • Disable or restrict access to the Tabularis MCP interface for untrusted AI agents and clients until an upstream fix is available.
  • Audit recent MCP run_query activity for SELECT statements referencing setval, nextval, query_to_xml, or similar functions.

Patch Information

No fixed version is identified in the published advisory at the time of writing. The vulnerability is documented in the Vulncheck Advisory: Tabularis Bypass and discussed in the HackMD Security Discussion. Monitor the GitHub Tabularis Repository for a release addressing the run_query classification logic in src-tauri/src/mcp/mod.rs.

Workarounds

  • Connect Tabularis using a database role that has only SELECT privileges on required tables and no EXECUTE on sequence or XML functions.
  • Place Tabularis behind a database proxy that parses incoming SQL and rejects SELECT statements calling side-effecting functions.
  • Operate Tabularis against a read-replica so that any bypassed write fails at the database layer.
bash
# Configuration example: enforce read-only at the database layer
CREATE ROLE tabularis_ro LOGIN PASSWORD '***';
GRANT CONNECT ON DATABASE appdb TO tabularis_ro;
GRANT USAGE ON SCHEMA public TO tabularis_ro;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO tabularis_ro;
REVOKE EXECUTE ON FUNCTION setval(regclass, bigint) FROM tabularis_ro;
REVOKE EXECUTE ON FUNCTION nextval(regclass) FROM tabularis_ro;
REVOKE EXECUTE ON FUNCTION query_to_xml(text, boolean, boolean, text) FROM tabularis_ro;
ALTER ROLE tabularis_ro SET default_transaction_read_only = on;

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.