# CVE-2026-121747: nvm prints the contents of any readable file through a symlinked .nvmrc

Status: published. Published: 2026-11-04. Updated: 2026-11-04.

Node Version Manager (nvm) is a POSIX-compliant shell function for managing multiple node.js versions. In versions 0.2.0 through 0.40.8, nvm does not check whether `.nvmrc` is a symbolic link. A repository or archive that ships `.nvmrc` as a symlink to another file (for example `../../.npmrc`, or `/proc/self/environ` on Linux) makes a plain `nvm use`, `nvm install`, `nvm which`, `nvm exec`, `nvm run`, or `nvm-exec` read that file and print its contents in the invalid-`.nvmrc` message (even with `--silent`) or, for a one-line file, in the `Found ... with version <...>` message; with the README's zsh `load-nvmrc` or bash `cdnvm` hook installed, entering the directory is enough. nvm sends the content nowhere; the attacker learns it only where they can see the victim's output, such as a CI log for a contributed branch. Version 0.41.0 still follows a symlinked `.nvmrc`, so deliberate links to another version file keep working, but never prints its content, and accepts it only if it contains a version or the name of an existing alias; the README's bash `cdnvm` hook, which read `.nvmrc` itself, now gets the version from nvm, so users of that hook must also update their copy of it.

## Remediation

- fix: Upgrade to nvm 0.41.0 or later. (source: CNA: harborist)
- workaround: Until upgrading, check for a symlinked `.nvmrc` (`ls -l .nvmrc`) before running nvm in an untrusted project directory, and do not run nvm in CI for untrusted branches where its output is visible to their authors. (source: CNA: harborist)
- fix: The reporting source identifies this reference as a patch. Check the advisory for affected versions and supported release branches. (source: CNA: harborist) — https://github.com/nvm-sh/nvm/commit/67268ebcb6e1a26ae3d71b3710d6333bb7358662
- fix: The reporting source identifies this reference as a patch. Check the advisory for affected versions and supported release branches. (source: CNA: harborist) — https://github.com/nvm-sh/nvm/commit/c314f1cbb3c301c587a4e4f96511d31f1134ffd1

## Affected products and versions

- nvm-sh / nvm: ≥ 0.2.0; < 0.41.0 (affected, semver). Source: CNA: harborist

## Severity and prioritization

- CVSS 4.0: 6.7 (medium); CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N; source: CNA: harborist

- CVSS 3.1: 5.5 (medium); CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N; source: CNA: harborist

- CVSS 4.0: 6.7 (medium); CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X; source: NVD: 7ffcee3d-2c14-4c3e-b844-86c6a321a158

- CVSS 3.1: 5.5 (medium); CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N; source: NVD: 7ffcee3d-2c14-4c3e-b844-86c6a321a158

- CISA KEV: No listing in collected sources

- EPSS: Not available

- SSVC: Not available

- Weaknesses: CWE-59, CWE-61, CWE-200

## Exploit evidence

No exploit evidence in collected sources. This is not proof of no exploitation.

## References

- https://github.com/nvm-sh/nvm/security/advisories/GHSA-j6ch-mq5c-3h4x (CNA: harborist; vendor-advisory)

- https://github.com/nvm-sh/nvm/commit/67268ebcb6e1a26ae3d71b3710d6333bb7358662 (CNA: harborist; patch)

- https://github.com/nvm-sh/nvm/commit/c314f1cbb3c301c587a4e4f96511d31f1134ffd1 (CNA: harborist; patch)

- https://github.com/nvm-sh/nvm/commit/67268ebcb6e1a26ae3d71b3710d6333bb7358662 (7ffcee3d-2c14-4c3e-b844-86c6a321a158)

- https://github.com/nvm-sh/nvm/commit/c314f1cbb3c301c587a4e4f96511d31f1134ffd1 (7ffcee3d-2c14-4c3e-b844-86c6a321a158)

- https://github.com/nvm-sh/nvm/security/advisories/GHSA-j6ch-mq5c-3h4x (7ffcee3d-2c14-4c3e-b844-86c6a321a158)

## Provenance

- CNA: harborist: https://www.cve.org/CVERecord?id=CVE-2026-121747; retrieved 2026-11-04; source updated 2026-11-04

- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-121747; retrieved 2026-11-05; source updated 2026-11-04

Revision: 81493c6c3805bb0f3e85cfa0f8ad0e90721c3c72f5283f3601d3b22de55aff5d

Canonical: https://y2.dev/cve/CVE-2026-121747

## Agent and API access

Public CVE pages, Markdown, and JSON are free to read without an account or API key.

- Public catalog: https://y2.dev/cve/index.json. Follow nextCursor with the same search, filters, sort, and limit (1–100). A null cursor marks the end.

- WebMCP: search_cve_disclosures, get_cve_disclosure, get_cve_page_markdown, get_y2_cve_access. Available in compatible browsers.

- Cyber API: https://api.y2.dev/api/v2/cyber/cves and https://api.y2.dev/api/v2/cyber/cves/{cveId}.

- Y2 Pro or Elite: create a workspace API key with the intel:cyber scope and send Authorization: Bearer <Y2_API_KEY>. Setup: https://y2.dev/docs/api/create-key.

- x402: Pay per request without an account or API key. Omit Authorization, read the HTTP 402 PAYMENT-REQUIRED challenge, validate its current requirements, and retry with PAYMENT-SIGNATURE through an authorized payment client. These browser tools never make payments. Guide: https://y2.dev/docs/api/x402.

- OpenAPI: https://y2.dev/api/openapi.yaml. Agent access metadata: https://y2.dev/cve/agent.json.

Collected public records only. Check source status for coverage and freshness.