CVE-2026-138027
7.5HighPublished Nov 27, 2026 · NVD status: Received · AI triage by gemini-3.1-flash-lite
High
0CVSS v3.110
- Attack vector
- Network
- Complexity
- High
- Privileges
- None
- User action
- Required
- Impact
- Full C/I/A compromise
- Weakness
- CWE-749
What an attacker gets
Attackers can read or write arbitrary files and perform server-side request forgery. They need to inject a malicious prompt into the LLM via recorded logs or topics to trigger the unsandboxed SQL execution.
Root cause
The query_messages tool allows unsandboxed DuckDB SQL execution, enabling dangerous commands like read_csv_auto and COPY TO.
Affected versions
bagel-mcp before 2.5.5
CVSS v3.1 · CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H
Fix & remediation
Upgrade to bagel-mcp version 2.5.5 or later. If you cannot upgrade, disable the query_messages tool in the MCP configuration.
$ pip install --upgrade bagel-mcpAI-suggested. Run it in staging first and check it against the vendor advisory. Why?
NVD description
Bagel (bagel-mcp) before 2.5.5 exposes unsandboxed DuckDB SQL execution through the read-only annotated query_messages MCP tool, allowing file access and network requests. Attackers who prompt-inject the driving LLM via recorded logs or topics can invoke read_csv_auto, COPY TO, or httpfs to read and write files and perform server-side request forgery.
References
- https://github.com/Extelligence-ai/bagel/blob/v2.5.4/bagel_mcp/query.py#L11-L29
- https://github.com/Extelligence-ai/bagel/blob/v2.5.4/bagel_mcp/server.py#L246
- https://github.com/Extelligence-ai/bagel/commit/cbec958edd9ce105b9005c9e31631b1dc420ee4f
- https://github.com/Extelligence-ai/bagel/releases/tag/v2.5.5
- https://github.com/Extelligence-ai/bagel/security/advisories/GHSA-gx2g-3pch-43q5
- https://www.vulncheck.com/advisories/bagel-before-2.5.5-unsandboxed-duckdb-sql-execution-via-query-messages
Related Critical / High CVEs
More fully triaged vulnerabilities you may want to check next.
- CVE-2026-1381627.0HighAttackers can execute arbitrary code or crash the application by providing a crafted backup file. This requires a user to perform a restore or addnew operation on an attached Alcatel phone.
- CVE-2026-1381617.8HighAttackers can achieve code execution by providing a crafted backup file with an overlong MD5 value. This requires a user to process a malicious file using convertbackup or restore.
- CVE-2026-1381607.8HighAttackers can execute arbitrary code or crash the application by providing a malicious backup file. This requires a user to trigger a restore or backup process with a crafted file.
- CVE-2026-1381597.5HighRemote attackers can execute arbitrary code or crash the application by sending a response body larger than 2 GB. This requires a user to browse to an attacker-controlled HTTP, FTP, or gopher server.
- CVE-2026-1381548.6HighAttackers can execute arbitrary code on your machine as the current user. This requires a user to subscribe to a malicious Steam Workshop mod.
- CVE-2026-1381198.8HighUnauthenticated attackers can steal session cookies and take over Kestra instances by tricking a logged-in user into clicking a malicious link. This is a reflected cross-site scripting attack that executes arbitrary JavaScript in the user's browser.