GHSA-j4g3-3q8x-jxqp: Dbt core Dbt-core's Secret Env Vars Written Vulnerability

LOW
CVSS 3.2
CWE-315
Published
Advisory Summary

GHSA-j4g3-3q8x-jxqp is a LOW (CVSS 3.2) dbt-core's secret env vars written vulnerability (CWE-315: Cleartext Storage of Sensitive Information in a Cookie) affecting Dbt core libraries in the PyPI ecosystem. The issue involves dbt-core's secret env vars written to package-lock.json in plaintext. Remediation is available by upgrading affected packages to version 1.7.3.

GHSA-j4g3-3q8x-jxqp at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-j4g3-3q8x-jxqp
Severity LOW
CVSS v3.1 Base Score 3.2
CWE Classification CWE-315: Cleartext Storage of Sensitive Information in a Cookie
Affected Product Dbt core
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 3.2

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

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

How to Fix GHSA-j4g3-3q8x-jxqp

To remediate this vulnerability, upgrade all affected Dbt core 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-core fixed: 1.7.3
pip install dbt-core>=1.7.3
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-core

How to Check if You Are Affected

To determine whether your Python environment is affected by GHSA-j4g3-3q8x-jxqp, inspect your installed packages using pip:

pip show dbt-core

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

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

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-315: Cleartext Storage of Sensitive Information in a Cookie, where the product stores sensitive information in cleartext in a cookie. In Dbt core, 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

### Impact When used to pull source code from a private repository using a Personal Access Token (PAT), some versions of dbt-core write a URL with the PAT in plaintext to the `package-lock.yml` file. ### Patches The bug has been fixed in [dbt-core v1.7.3](https://github.com/dbt-labs/dbt-core/releases/tag/v1.7.3). ### Mitigations Remove any git URLs with plaintext secrets from `package-lock.yml` file(s) on servers, workstations, or in source control. Rotate any tokens that have been written to version-controlled files.

GHSA-j4g3-3q8x-jxqp Affected Dbt core Versions

1 component(s)
Fixed Versions:
1.7.3
Product / Package Ecosystem Affected Versions Fixed Version
dbt-core
PyPI
≥ 1.7.0
< 1.7.3
1.7.3

References

Frequently Asked Questions

What is GHSA-j4g3-3q8x-jxqp?
GHSA-j4g3-3q8x-jxqp is a security vulnerability in Dbt core involving dbt-core's secret env vars written to package-lock.json in plaintext under CWE-315: Cleartext Storage of Sensitive Information in a Cookie.
Which Dbt core versions are affected?
Affected versions include releases prior to 1.7.3 across affected packages: dbt-core.
What version fixes GHSA-j4g3-3q8x-jxqp?
Upgrading to 1.7.3 (or the latest patched release for your respective branch) resolves the vulnerability.
Is dbt-core affected?
Yes, dbt-core is affected in releases prior to 1.7.3. Upgrade your dependency to 1.7.3 or later.
What is the CVSS score of GHSA-j4g3-3q8x-jxqp?
GHSA-j4g3-3q8x-jxqp has a CVSS v3.1 base score of 3.2 (LOW) with vector string CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:L/I:N/A:N.
What CWE is associated with GHSA-j4g3-3q8x-jxqp?
GHSA-j4g3-3q8x-jxqp is classified under CWE-315: Cleartext Storage of Sensitive Information in a Cookie (The product stores sensitive information in cleartext in a cookie.).
How can I check PyPI dependencies for GHSA-j4g3-3q8x-jxqp?
Run the dependency tree command: 'pip show dbt-core'. 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-j4g3-3q8x-jxqp",
  "modified" : "2023-12-08T15:38:37Z",
  "published" : "2023-12-08T15:38:37Z",
  "aliases" : [ ],
  "summary" : "dbt-core's secret env vars written to package-lock.json in plaintext",
  "details" : "### Impact\n\nWhen used to pull source code from a private repository using a Personal Access Token (PAT), some versions of dbt-core write a URL with the PAT in plaintext to the `package-lock.yml` file.\n\n### Patches\n\nThe bug has been fixed in [dbt-core v1.7.3](https://github.com/dbt-labs/dbt-core/releases/tag/v1.7.3).\n\n### Mitigations\n\nRemove any git URLs with plaintext secrets from `package-lock.yml` file(s) on servers, workstations, or in source control. Rotate any tokens that have been written to version-controlled files.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:L/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "dbt-core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.7.0"
      }, {
        "fixed" : "1.7.3"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/dbt-labs/dbt-core/security/advisories/GHSA-j4g3-3q8x-jxqp"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/dbt-labs/dbt-core/commit/09f5bb3dcffeda7a60ad2b22c2891f237628ecd1"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/dbt-labs/dbt-core"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/dbt-labs/dbt-core/releases/tag/v1.7.3"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-315" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-12-08T15:38:37Z",
    "nvd_published_at" : null
  }
}