Directory Traversal Affecting nodegit package, versions <0.26.3


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team

    Threat Intelligence

    EPSS
    0.26% (66th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk ID SNYK-JS-NODEGIT-542720
  • published 7 Jan 2020
  • disclosed 10 Dec 2019
  • credit Unknown

How to fix?

Upgrade nodegit to version 0.26.3 or higher.

Overview

nodegit is a Node bindings to the libgit2 project.

Affected versions of this package are vulnerable to Directory Traversal. While the only permitted drive letters for physical drives on Windows are letters of the US-English alphabet, this restriction does not apply to virtual drives assigned via subst <letter>: <path>. Git mistook such paths for relative paths, allowing writing outside of the worktree while cloning.

This vulnerability can only be exploited on Windows, and only when the targeted user is known to use non-alphabetical drive letters on logical drives registered with the subst.exe command, allowing to overwrite arbitrary files on said logical drive during a regular git clone.

CVSS Scores

version 3.1
Expand this section

Snyk

Recommended
8.9 high
  • Attack Vector (AV)
    Network
  • Attack Complexity (AC)
    High
  • Privileges Required (PR)
    None
  • User Interaction (UI)
    None
  • Scope (S)
    Changed
  • Confidentiality (C)
    Low
  • Integrity (I)
    High
  • Availability (A)
    High
Expand this section

NVD

7.5 high
Expand this section

SUSE

7.5 high