CVE-2026-44969: Dbt mcp Dbt MCP Server Logs Tool Vulnerability

LOW
Advisory Identifier: GHSA-7xgw-6qf3-7w59
CVSS 2.5
CWE-532
Published
Advisory Summary

CVE-2026-44969 is a LOW (CVSS 2.5) dbt mcp server logs tool vulnerability (CWE-532: Insertion of Sensitive Information into Log File) affecting Dbt mcp libraries in the PyPI ecosystem. The issue involves dbt mcp server logs tool arguments including sql queries and credentials in plaintext without redaction when file logging is enabled. Remediation is available by upgrading affected packages to version 1.17.1.

CVE-2026-44969 at a Glance

CVE Identifier CVE-2026-44969
GHSA Identifier GHSA-7xgw-6qf3-7w59
Severity LOW
CVSS v3.1 Base Score 2.5
CWE Classification CWE-532: Insertion of Sensitive Information into Log File
Affected Product Dbt mcp
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 2.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N).

Attack Vector Local (AV:L)
Attack Complexity High (AC:H)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality Low (C:L)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2026-44969

To remediate this vulnerability, upgrade all affected Dbt mcp dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

dbt-mcp fixed: 1.17.1
pip install dbt-mcp>=1.17.1
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show dbt-mcp

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-44969, inspect your installed packages using pip:

pip show dbt-mcp

Analyze the terminal output to locate any version of Dbt mcp in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.17.1), your application is affected.

Note: The pip show dbt-mcp command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-532: Insertion of Sensitive Information into Log File, where the product writes sensitive information to a log file. In Dbt mcp, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

*Discovered through manual source code review. Verified by PoC execution against a local dbt-mcp v1.15.1 installation.* ### Summary `DbtMCP.call_tool()` in `src/dbt_mcp/mcp/server.py` logs the complete raw `arguments` dictionary at `INFO` level on every tool invocation (line 67) and again at `ERROR` level if the call raises an exception (lines 77–79). No field is redacted before logging. When the documented `DBT_MCP_SERVER_FILE_LOGGING=true` feature is enabled, these log records are written to `dbt-mcp.log` in the project root directory as plaintext. Sensitive data — raw SQL queries, `--vars` payloads carrying credentials, node selectors — persists on disk indefinitely with no automatic rotation or deletion. ### Details **Vulnerable log statements (`server.py`):** ```python # Line 67 — emitted before every tool execution logger.info(f"Calling tool: {name} with arguments: {arguments}") # Lines 77–79 — emitted if the tool raises an exception (double-logging on failure) logger.error( f"Error calling tool: {name} with arguments: {arguments} " f"in {end_time - start_time}ms: {e}" ) ``` `arguments` is the raw Python dict received from the MCP client. It is string-interpolated directly into the log message. On a tool call that raises an exception, the same dict is logged twice — once at INFO and once at ERROR. File logging is activated by `DBT_MCP_SERVER_FILE_LOGGING=true` (a documented feature in the project README). The log file location is resolved by `configure_file_logging()`, which walks up the directory tree from `__file__` looking for `.git` or `pyproject.toml`, falling back to `$HOME`. Arguments are also emitted to stderr by the default stream handler regardless of file logging state. ### PoC **MCP client script — triggers real tool calls and verifies log file contents:** ```python #!/usr/bin/env python3 # poc4_tool_args_logged.py # Vulnerable code: src/dbt_mcp/mcp/server.py line 67, 77-79 # configure_file_logging(): src/dbt_mcp/telemetry/logging.py import logging from pathlib import Path LOG_FILENAME = "dbt-mcp.log" def configure_file_logging(log_level: int = logging.INFO) -> Path: """Reproduction of configure_file_logging() from telemetry/logging.py.""" module_path = Path(__file__).resolve().parent home = Path.home().resolve() for candidate in [module_path, *module_path.parents]: if (candidate / ".git").exists() or (candidate / "pyproject.toml").exists() or candidate == home: repo_root = candidate break log_path = repo_root / LOG_FILENAME root_logger = logging.getLogger() root_logger.setLevel(log_level) file_handler = logging.FileHandler(log_path, encoding="utf-8") file_handler.setLevel(log_level) file_handler.setFormatter( logging.Formatter("%(asctime)s %(levelname)s [%(name)s] %(message)s") ) root_logger.addHandler(file_handler) return log_path log_path = configure_file_logging() server_logger = logging.getLogger("dbt_mcp.mcp.server") # Exact log statements from server.py line 67 and line 77-79 name = "show" arguments = {"sql_query": "SELECT ssn, credit_card_number, salary FROM customers WHERE id = 42", "limit": 5} server_logger.info(f"Calling tool: {name} with arguments: {arguments}") name2 = "run" arguments2 = {"node_selection": "sensitive_model", "vars": '{"db_password": "hunter2", "api_key": "sk-prod-abc123xyz"}', "is_full_refresh": False} server_logger.info(f"Calling tool: {name2} with arguments: {arguments2}") # Verify file contents lines = log_path.read_text(encoding="utf-8").splitlines() poc_lines = [l for l in lines if "dbt_mcp.mcp.server" in l] print(f"[log file: {log_path}]") for line in poc_lines: print(f" {line}") keywords = ["ssn", "credit_card_number", "salary", "db_password", "api_key"] found = [kw for kw in keywords if any(kw in l for l in poc_lines)] if found: print(f"\n[CONFIRMED] Sensitive keywords in plaintext log: {found}") print(f"[CONFIRMED] No redaction applied. File persists at {log_path}") ``` **Expected log file entries:** ```` 2026-04-27 ... INFO [dbt_mcp.mcp.server] Calling tool: show with arguments: {'sql_query': 'SELECT ssn, credit_card_number, salary FROM customers', 'limit': 5} 2026-04-27 ... INFO [dbt_mcp.mcp.server] Calling tool: run with arguments: {'node_selection': 'sensitive_model', 'vars': '{"db_password":"hunter2","api_key":"sk-prod-abc123"}', 'is_full_refresh': False} [CONFIRMED] Sensitive keywords in plaintext log: ['ssn', 'credit_card_number', 'salary', 'db_password', 'api_key'] [CONFIRMED] No redaction applied. ```` <img width="3798" height="462" alt="image" src="https://github.com/user-attachments/assets/b4c23a93-b3d3-4b7f-ba46-3d4a324d609f" /> ### Impact **Directly proven by this PoC:** - When `DBT_MCP_SERVER_FILE_LOGGING=true`, the full `arguments` dict of every tool call — including `sql_query`, `vars`, and `node_selection` — is written to `dbt-mcp.log` in plaintext on every invocation. - A tool call that raises an exception produces **two** log entries with the same sensitive content (INFO + ERROR double-logging). - The log file has no automatic rotation, expiry, or access restriction beyond filesystem permissions. Combined with Advisory 3 (telemetry), a single `show` tool call containing PII produces one telemetry transmission to dbt Labs **and** one (or two, on failure) persistent log entries on disk. ### Remediation **redact known-sensitive argument values before logging:** ```python _LOG_REDACT = frozenset({"sql_query", "vars"}) def _safe_args(arguments: dict) -> dict: return {k: "***redacted***" if k in _LOG_REDACT else v for k, v in arguments.items()} # server.py line 67: logger.info(f"Calling tool: {name} with arguments: {_safe_args(arguments)}") # server.py lines 77-79: logger.error( f"Error calling tool: {name} with arguments: {_safe_args(arguments)} " f"in {end_time - start_time}ms: {e}" ) ``` **log argument keys only:** ```python logger.info(f"Calling tool: {name} with argument keys: {list(arguments.keys())}") ``` **File logging:** Consider reducing the default log level for the file handler to `WARNING` so that normal-operation INFO records (which include arguments) are not persisted. Sensitive content would only appear in file logs on error.

CVE-2026-44969 Affected Dbt mcp Versions

1 component(s)
Fixed Versions:
1.17.1
Product / Package Ecosystem Affected Versions Fixed Version
dbt-mcp
PyPI
< 1.17.1
1.17.1

References

Frequently Asked Questions

What is CVE-2026-44969?
CVE-2026-44969 is a security vulnerability in Dbt mcp involving dbt MCP Server Logs Tool Arguments Including SQL Queries and Credentials in Plaintext Without Redaction When File Logging Is Enabled under CWE-532: Insertion of Sensitive Information into Log File.
Which Dbt mcp versions are affected?
Affected versions include releases prior to 1.17.1 across affected packages: dbt-mcp.
What version fixes CVE-2026-44969?
Upgrading to 1.17.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is dbt-mcp affected?
Yes, dbt-mcp is affected in releases prior to 1.17.1. Upgrade your dependency to 1.17.1 or later.
What is the CVSS score of CVE-2026-44969?
CVE-2026-44969 has a CVSS v3.1 base score of 2.5 (LOW) with vector string CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N.
What CWE is associated with CVE-2026-44969?
CVE-2026-44969 is classified under CWE-532: Insertion of Sensitive Information into Log File (The product writes sensitive information to a log file.).
How can I check PyPI dependencies for CVE-2026-44969?
Run the dependency tree command: 'pip show dbt-mcp'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-7xgw-6qf3-7w59",
  "modified" : "2026-05-14T18:24:44Z",
  "published" : "2026-05-14T18:24:44Z",
  "aliases" : [ "CVE-2026-44969" ],
  "summary" : "dbt MCP Server Logs Tool Arguments Including SQL Queries and Credentials in Plaintext Without Redaction When File Logging Is Enabled",
  "details" : "*Discovered through manual source code review. Verified by PoC execution against a local dbt-mcp v1.15.1 installation.*\n\n### Summary\n\n`DbtMCP.call_tool()` in `src/dbt_mcp/mcp/server.py` logs the complete raw `arguments` dictionary at `INFO` level on every tool invocation (line 67) and again at `ERROR` level if the call raises an exception (lines 77–79). No field is redacted before logging. When the documented `DBT_MCP_SERVER_FILE_LOGGING=true` feature is enabled, these log records are written to `dbt-mcp.log` in the project root directory as plaintext. Sensitive data — raw SQL queries, `--vars` payloads carrying credentials, node selectors — persists on disk indefinitely with no automatic rotation or deletion.\n\n### Details\n\n**Vulnerable log statements (`server.py`):**\n\n```python\n# Line 67 — emitted before every tool execution\nlogger.info(f\"Calling tool: {name} with arguments: {arguments}\")\n\n# Lines 77–79 — emitted if the tool raises an exception (double-logging on failure)\nlogger.error(\n    f\"Error calling tool: {name} with arguments: {arguments} \"\n    f\"in {end_time - start_time}ms: {e}\"\n)\n```\n\n`arguments` is the raw Python dict received from the MCP client. It is string-interpolated directly into the log message. On a tool call that raises an exception, the same dict is logged twice — once at INFO and once at ERROR.\n\nFile logging is activated by `DBT_MCP_SERVER_FILE_LOGGING=true` (a documented feature in the project README). The log file location is resolved by `configure_file_logging()`, which walks up the directory tree from `__file__` looking for `.git` or `pyproject.toml`, falling back to `$HOME`. Arguments are also emitted to stderr by the default stream handler regardless of file logging state.\n\n### PoC\n\n**MCP client script — triggers real tool calls and verifies log file contents:**\n\n```python\n#!/usr/bin/env python3\n# poc4_tool_args_logged.py\n# Vulnerable code: src/dbt_mcp/mcp/server.py line 67, 77-79\n# configure_file_logging(): src/dbt_mcp/telemetry/logging.py\n\nimport logging\nfrom pathlib import Path\n\nLOG_FILENAME = \"dbt-mcp.log\"\n\ndef configure_file_logging(log_level: int = logging.INFO) -> Path:\n    \"\"\"Reproduction of configure_file_logging() from telemetry/logging.py.\"\"\"\n    module_path = Path(__file__).resolve().parent\n    home = Path.home().resolve()\n    for candidate in [module_path, *module_path.parents]:\n        if (candidate / \".git\").exists() or (candidate / \"pyproject.toml\").exists() or candidate == home:\n            repo_root = candidate\n            break\n    log_path = repo_root / LOG_FILENAME\n    root_logger = logging.getLogger()\n    root_logger.setLevel(log_level)\n    file_handler = logging.FileHandler(log_path, encoding=\"utf-8\")\n    file_handler.setLevel(log_level)\n    file_handler.setFormatter(\n        logging.Formatter(\"%(asctime)s %(levelname)s [%(name)s] %(message)s\")\n    )\n    root_logger.addHandler(file_handler)\n    return log_path\n\nlog_path = configure_file_logging()\nserver_logger = logging.getLogger(\"dbt_mcp.mcp.server\")\n\n# Exact log statements from server.py line 67 and line 77-79\nname = \"show\"\narguments = {\"sql_query\": \"SELECT ssn, credit_card_number, salary FROM customers WHERE id = 42\", \"limit\": 5}\nserver_logger.info(f\"Calling tool: {name} with arguments: {arguments}\")\n\nname2 = \"run\"\narguments2 = {\"node_selection\": \"sensitive_model\", \"vars\": '{\"db_password\": \"hunter2\", \"api_key\": \"sk-prod-abc123xyz\"}', \"is_full_refresh\": False}\nserver_logger.info(f\"Calling tool: {name2} with arguments: {arguments2}\")\n\n# Verify file contents\nlines = log_path.read_text(encoding=\"utf-8\").splitlines()\npoc_lines = [l for l in lines if \"dbt_mcp.mcp.server\" in l]\nprint(f\"[log file: {log_path}]\")\nfor line in poc_lines:\n    print(f\"  {line}\")\n\nkeywords = [\"ssn\", \"credit_card_number\", \"salary\", \"db_password\", \"api_key\"]\nfound = [kw for kw in keywords if any(kw in l for l in poc_lines)]\nif found:\n    print(f\"\\n[CONFIRMED] Sensitive keywords in plaintext log: {found}\")\n    print(f\"[CONFIRMED] No redaction applied. File persists at {log_path}\")\n```\n\n**Expected log file entries:**\n\n````\n2026-04-27 ... INFO [dbt_mcp.mcp.server] Calling tool: show with arguments:\n  {'sql_query': 'SELECT ssn, credit_card_number, salary FROM customers', 'limit': 5}\n\n2026-04-27 ... INFO [dbt_mcp.mcp.server] Calling tool: run with arguments:\n  {'node_selection': 'sensitive_model',\n   'vars': '{\"db_password\":\"hunter2\",\"api_key\":\"sk-prod-abc123\"}',\n   'is_full_refresh': False}\n\n[CONFIRMED] Sensitive keywords in plaintext log: ['ssn', 'credit_card_number', 'salary', 'db_password', 'api_key']\n[CONFIRMED] No redaction applied.\n````\n\n<img width=\"3798\" height=\"462\" alt=\"image\" src=\"https://github.com/user-attachments/assets/b4c23a93-b3d3-4b7f-ba46-3d4a324d609f\" />\n\n### Impact\n\n**Directly proven by this PoC:**\n\n- When `DBT_MCP_SERVER_FILE_LOGGING=true`, the full `arguments` dict of every tool call — including `sql_query`, `vars`, and `node_selection` — is written to `dbt-mcp.log` in plaintext on every invocation.\n- A tool call that raises an exception produces **two** log entries with the same sensitive content (INFO + ERROR double-logging).\n- The log file has no automatic rotation, expiry, or access restriction beyond filesystem permissions.\n\nCombined with Advisory 3 (telemetry), a single `show` tool call containing PII produces one telemetry transmission to dbt Labs **and** one (or two, on failure) persistent log entries on disk.\n\n### Remediation\n\n**redact known-sensitive argument values before logging:**\n\n```python\n_LOG_REDACT = frozenset({\"sql_query\", \"vars\"})\n\ndef _safe_args(arguments: dict) -> dict:\n    return {k: \"***redacted***\" if k in _LOG_REDACT else v\n            for k, v in arguments.items()}\n\n# server.py line 67:\nlogger.info(f\"Calling tool: {name} with arguments: {_safe_args(arguments)}\")\n\n# server.py lines 77-79:\nlogger.error(\n    f\"Error calling tool: {name} with arguments: {_safe_args(arguments)} \"\n    f\"in {end_time - start_time}ms: {e}\"\n)\n```\n\n**log argument keys only:**\n\n```python\nlogger.info(f\"Calling tool: {name} with argument keys: {list(arguments.keys())}\")\n```\n\n**File logging:** Consider reducing the default log level for the file handler to `WARNING` so that normal-operation INFO records (which include arguments) are not persisted. Sensitive content would only appear in file logs on error.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "dbt-mcp"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.17.1"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 1.17.0"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/dbt-labs/dbt-mcp/security/advisories/GHSA-7xgw-6qf3-7w59"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/dbt-labs/dbt-mcp"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/dbt-labs/dbt-mcp/releases/tag/v1.17.1"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-532" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-05-14T18:24:44Z",
    "nvd_published_at" : null
  }
}