<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:webfeeds="http://webfeeds.org/rss/1.0"><channel><title>Node Version Manager (0.31.2 &lt;= 0.40.5) - CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/products/node-version-manager-0.31.2--0.40.5/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata. Fed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Thu, 29 Oct 2026 07:09:42 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/products/node-version-manager-0.31.2--0.40.5/feed.xml" rel="self" type="application/rss+xml"/><image><url>https://feed.craftedsignal.io/favicon-32x32.png</url><title>CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/</link><width>32</width><height>32</height></image><webfeeds:icon>https://feed.craftedsignal.io/favicon.svg</webfeeds:icon><item><title>Node Version Manager: Command injection in nvm_ls (CVE-2026-118905)</title><link>https://feed.craftedsignal.io/briefs/2026-10-nvm-command-injection/</link><pubDate>Thu, 29 Oct 2026 07:09:42 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2026-10-nvm-command-injection/</guid><description>Node Version Manager (nvm) versions 0.31.2 through 0.40.5 are vulnerable to command injection via malicious version strings due to improper sanitization in the nvm_ls function when invoked with tools like nvm use or automated shell hooks.</description><content:encoded><![CDATA[<p>CVE-2026-118905 describes a command injection vulnerability in nvm (Node Version Manager) versions 0.31.2 through 0.40.5. The <code>nvm_ls</code> function uses an improperly sanitized sed program to filter installed versions. By providing a version string containing specific characters such as <code>#</code>, an attacker can escape the intended sed address context and inject arbitrary commands.</p>
<p>The vulnerability is triggered when an attacker-controlled version string is passed to commands like <code>nvm use</code>, <code>nvm which</code>, <code>nvm ls</code>, <code>nvm version</code>, <code>nvm run</code>, or <code>nvm exec</code>, or via the <code>NODE_VERSION</code> environment variable. Users employing auto-switching hooks (e.g., <code>cdnvm</code> or <code>load-nvmrc</code>) or scripts that pass raw <code>.nvmrc</code> contents to nvm commands are at particular risk, as changing to a directory containing a malicious <code>.nvmrc</code> file can trigger execution. The issue is resolved in version 0.40.6.</p>
<h2 id="impact">Impact</h2>
<p>Successful exploitation allows arbitrary command execution as the user running the nvm command or the shell hook. Using GNU sed, this can lead to direct shell command execution; using BSD sed, this can lead to unauthorized file read and write operations.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Patch nvm to version 0.40.6 or later immediately.</li>
<li>Audit environments for scripts that pass file contents or environment variables directly to <code>nvm</code> commands without validation.</li>
<li>Audit shell initialization files (<code>.bashrc</code>, <code>.zshrc</code>) for <code>cdnvm</code> or <code>load-nvmrc</code> hooks that automatically process <code>.nvmrc</code> files without sanitization.</li>
</ul>
]]></content:encoded><category domain="severity">high</category><category domain="type">advisory</category><category>command-injection</category><category>vulnerability</category><category>linux</category><category>macos</category></item></channel></rss>