Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. dbt-common
  4. ›
  5. GHSA-w75w-9qv4-j5xj

GHSA-w75w-9qv4-j5xj: dbt-common's commonprefix() doesn't protect against path traversal

March 5, 2026

What kind of vulnerability is it? Who is impacted?

A path traversal vulnerability exists in dbt-common’s safe_extract() function used when extracting tarball archives. The function uses os.path.commonprefix() to validate that extracted files remain within the intended destination directory. However, commonprefix() compares paths character-by-character rather than by path components, allowing a malicious tarball to write files to sibling directories with matching name prefixes.

For example, when extracting to /tmp/packages, a crafted tarball could write files to /tmp/packagesevil/ by exploiting the character-based prefix matching.

This vulnerability affects users who:

  • Install dbt packages from untrusted sources
  • Process tarball archives through dbt-common’s extraction utilities

The practical risk is limited because:

  • Exploitation requires a malicious tarball to be processed
  • File writes are restricted to sibling directories with matching prefixes (not arbitrary paths)
  • Packages from trusted sources (dbt Hub) are not affected

This is similar to CVE-2026-1703 in pip, which had a CVSS score of 3.9 (Low).

References

  • docs.python.org/3/library/os.path.html
  • github.com/advisories/GHSA-6vgw-5pg2-w6jp
  • github.com/advisories/GHSA-w75w-9qv4-j5xj
  • github.com/dbt-labs/dbt-common
  • github.com/dbt-labs/dbt-common/commit/e547954a48bac9394ef6eb98432e429dce9a7709
  • github.com/dbt-labs/dbt-common/security/advisories/GHSA-w75w-9qv4-j5xj
  • github.com/pypa/pip/pull/13777

Code Behaviors & Features

Detect and mitigate GHSA-w75w-9qv4-j5xj with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions before 1.34.2, all versions starting from 1.35.0 before 1.37.3

Fixed versions

  • 1.34.2
  • 1.37.3

Solution

Upgrade to versions 1.34.2, 1.37.3 or above.

Impact 3.5 LOW

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:N/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Source file

pypi/dbt-common/GHSA-w75w-9qv4-j5xj.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:15:57 +0000.