๐Ÿ” CVE Alert

CVE-2026-94185

MEDIUM 5.5

nvm alias resolution follows `..` and discloses files outside $NVM_DIR/alias

CVSS Score
5.5
EPSS Score
0.0%
EPSS Percentile
0th

nvm resolves a requested version or alias by treating it as a filename under $NVM_DIR/alias. Before 0.40.8, nvm_alias() concatenated the requested name onto that directory and read the result with no containment check, so a name containing a `..` component escaped the alias directory; under the default layout an alias such as `../../.npmrc` resolves to a file in the user's home directory. nvm_print_alias_file() then emits every non-comment, non-empty line of whatever was opened. A version string taken from an untrusted .nvmrc reaches this path, so a developer who runs `nvm use`, `nvm install`, or `nvm which` inside an attacker-supplied repository discloses the first non-comment line of an arbitrary file readable by that user, in the resulting "is not yet installed" error message. A user-supplied `nvm alias <traversing-name>` discloses every non-comment line of the target file. There is no integrity or availability impact, and no command execution on this path.

CWE CWE-22 CWE-200
Vendor nvm-sh
Product nvm
Published Sep 21, 2026
Stay Ahead of the Next One

Get instant alerts for nvm-sh nvm

Be the first to know when new medium vulnerabilities affecting nvm-sh nvm are published โ€” delivered to Slack, Telegram or Discord.

Get Free Alerts โ†’ Free ยท No credit card ยท 60 sec setup

CVSS v3 Breakdown

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

Affected Versions

nvm-sh / nvm
0 โ‰ค 0.40.7

References

NVD โ†— CVE.org โ†— EPSS Data โ†—
github.com: https://github.com/nvm-sh/nvm/security/advisories/GHSA-8grh-q73j-ffrc

Credits

vnth4nhnt of CyStack SecFathy