CVE-2026-100406

dbt: Unauthenticated Arbitrary SQL Execution in `dbt docs serve`

Published Oct 14, 2026 CVSS 4.0 · 8.2 High EPSS < 1% KEV · Not listed
Description
dbt enables data analysts and engineers to transform their data using the same practices that software engineers use to build applications. From 2.0.0-alpha.0 until 2.0.0-alpha.5, dbt docs serve exposes the unauthenticated POST /api/v1/query endpoint in crates/dbt-docs-server/src/handlers/query.rs, which passes caller-supplied SQL to DuckDbViewsBackend::query_arrow() in crates/dbt-index-core/src/backend.rs without authorization or an allowlist. A client that can reach the server can invoke DuckDB filesystem-reading functions to read files available to the dbt process, including files outside the docs index directory. The server binds to localhost by default, but operators can expose it to a network through the host option or DBT_DOCS_HOST setting. This issue is fixed in version 2.0.0-alpha.5.

Analysis

AI-generated

Technical impact

The vulnerability exists in the dbt "docs serve" feature, which exposes an unauthenticated POST /api/v1/query endpoint from versions 2.0.0-alpha.0 through 2.0.0-alpha.5. The endpoint forwards arbitrary client‑supplied SQL to DuckDB without any authorization checks or allowlist filtering. An attacker can thus execute arbitrary SQL commands, including DuckDB filesystem‑reading functions, and read files accessible to the dbt process, even files outside the docs index directory. This flaw enables local or remote data exfiltration and could allow an attacker to execute further malicious code via the database engine.

Affected Systems

Affected product is dbt Core from dbt Labs. All installations that run dbt docs serve between 2.0.0-alpha.0 and 2.0.0-alpha.5 are vulnerable. service to localhost, but operators can expose it to a network by setting the host option or the DBT_DOCS_HOST environment variable. Therefore, systems that expose the service beyond the local host are at risk for external attackers, while those that keep it bound locally are only vulnerable to local compromise.

Risk and Exploitability

The vulnerability has a CVSS score of 8.2, indicating a high severity. No EPSS score is available, and the issue is not listed in CISA KEV, suggesting no confirmed active exploitation at the time of analysis. The attack vector is likely local when the service is bound to localhost; however, the vulnerability explicitly enables network‑based exploitation when the service is exposed. An attacker can send a POST request with malicious SQL to /api/v1/query to read arbitrary files or perform other dangerous operations. Given the lack of authentication and authorization, exploitation can be straightforward once network or local access is achieved. Organizations with exposed dbt docs serve should therefore consider immediate remediation.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade dbt Core to version 2.0.0‑alpha.5 or later, where the unauthenticated endpoint is secured or removed.
  • If an upgrade cannot be performed immediately, configure the docs serve host to bind only to 127.0.0.1 or restrict the DBT_DOCS_HOST setting so that the service accepts connections solely from the local host.
  • Apply firewall or network ACL rules to block external traffic to the port used by dbt docs serve unless access is explicitly required.

Generated by OpenCVE AI on October 15, 2026 at 13:49 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Dbt-labs
Dbt-labs dbt-core
Vendors & Products Dbt-labs
Dbt-labs dbt-core
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description dbt enables data analysts and engineers to transform their data using the same practices that software engineers use to build applications. From 2.0.0-alpha.0 until 2.0.0-alpha.5, dbt docs serve exposes the unauthenticated POST /api/v1/query endpoint in crates/dbt-docs-server/src/handlers/query.rs, which passes caller-supplied SQL to DuckDbViewsBackend::query_arrow() in crates/dbt-index-core/src/backend.rs without authorization or an allowlist. A client that can reach the server can invoke DuckDB filesystem-reading functions to read files available to the dbt process, including files outside the docs index directory. The server binds to localhost by default, but operators can expose it to a network through the host option or DBT_DOCS_HOST setting. This issue is fixed in version 2.0.0-alpha.5.
Title dbt: Unauthenticated Arbitrary SQL Execution in `dbt docs serve`
Weaknesses CWE-200
CWE-22
CWE-306
References
Metrics cvssV4_0

{'score': 8.2, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-200

    Exposure of Sensitive Information to an Unauthorized Actor

  • CWE-22

    Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

  • CWE-306

    Missing Authentication for Critical Function

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Oct 20, 2026, 1:51 AM
Reserved
Sep 25, 2026, 8:08 PM
Status
Awaiting Analysis
Published
Oct 14, 2026, 7:16 PM
Modified
Oct 20, 2026, 2:17 AM