Node.jsApplication

CVE-2023-30585

HIGH · 7.5 CVSS v3.1 Published 2023-11-28
Fix available
A fix is available. Upgrade to 16.20.1 / 18.16.1 or later.
See remediation →
84/100
Remediation priority · High
Remotely reachable No privileges Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
A vulnerability has been identified in the Node.js (.msi version) installation process, specifically affecting Windows users who install Node.js using the .msi installer. This vulnerability emerges during the repair operation, where the "msiexec.exe" process, running under the NT AUTHORITY\SYSTEM context, attempts to read the %USERPROFILE% environment variable from the current user's registry. The issue arises when the path referenced by the %USERPROFILE% environment variable does not exist. In such cases, the "msiexec.exe" process attempts to create the specified path in an unsafe manner, potentially leading to the creation of arbitrary folders in arbitrary locations. The severity of this vulnerability is heightened by the fact that the %USERPROFILE% environment variable in the Windows registry can be modified by standard (or "non-privileged") users. Consequently, unprivileged actors, including malicious entities or trojans, can manipulate the environment variable key to deceive the privileged "msiexec.exe" process. This manipulation can result in the creation of folders in unintended and potentially malicious locations. It is important to note that this vulnerability is specific to Windows users who install Node.js using the .msi installer. Users who opt for other installation methods are not affected by this particular issue.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

The Node.js MSI installer for Windows has a vulnerability during repair operations where msiexec.exe (running as NT AUTHORITY\SYSTEM) reads the %USERPROFILE% environment variable from the current user's registry. If the path doesn't exist, msiexec attempts to create it unsafely, allowing unprivileged users to manipulate the registry to cause creation of arbitrary folders in arbitrary locations.

MitigationUse non-MSI installation methods (e.g., ZIP archive) until an official patch is released, or ensure the %USERPROFILE% path exists before running repair operations.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
Node.jsApplication
Affected:>= 16.0.0, < 16.20.1>= 18.0.0, < 18.16.1>= 20.0.0, < 20.3.1

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
None

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

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Check if Node.js is installed via MSI on Windows
    Check the Windows Registry at HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Node.js* for an MSI installation, or look for Node.js entries in the registry with 'InstallerType' value set to 'MSI'. You can also check C:\Program Files\Node.js\ for installation files.
    Affected if Node.js was installed using the Windows MSI installer package rather than a ZIP archive or other method.
  2. Determine the installed Node.js version
    Open Command Prompt or PowerShell and run: node --version to get the installed version number.
    Affected if The installed version falls within these ranges: >= 16.0.0 and < 16.20.1, OR >= 18.0.0 and < 18.16.1, OR >= 20.0.0 and < 20.3.1.
  3. Check if the MSI repair operation could be triggered
    Verify if the current user has permission to trigger a repair operation on the Node.js MSI installation, or check if automated tools (likepatch management software) run MSI repairs.
    Affected if A repair operation on the MSI installer can be triggered, as this is the specific action that triggers msiexec.exe to read the vulnerable %USERPROFILE% registry path.

Your environment is affected if Node.js was installed using the MSI installer on Windows and the installed version is 16.0.0-16.20.0, 18.0.0-18.16.0, or 20.0.0-20.3.0, and a repair operation can be performed.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 16.20.1 / 18.16.1 / 20.3.1 or later
Fixed in 16.20.118.16.120.3.1
Interim mitigation

Use non-MSI installation methods (e.g., ZIP archive) until an official patch is released, or ensure the %USERPROFILE% path exists before running repair operations.

Recommended fix High confidence

Node.js 16.20.1 (for 16.x), 18.16.1 (for 18.x), or 20.3.1 (for 20.x)

  1. Identify the currently installed Node.js version by running 'node --version' in Command Prompt or PowerShell
  2. Download the appropriate fixed version of Node.js for your major version branch from the official Node.js website (nodejs.org): for Node.js 16.x download 16.20.1, for 18.x download 18.16.1, or for 20.x download 20.3.1
  3. Run the new .msi installer as an administrator
  4. During installation, select 'Repair' if prompted, or manually run the repair operation via 'msiexec.exe /f' from an elevated command prompt to ensure the vulnerability is fully addressed
  5. Verify the upgrade was successful by running 'node --version' and 'npm --version'
Caveat Minor version upgrades within the same major branch typically have low risk; however, review the Node.js release notes for any breaking changes or deprecation notices in the target version

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Node.js Scoped from the published advisory
  • Consultation3.0 h
  • Implementation6.0 h
  • Testing4.0 h
  • Review / QA2.0 h
15.0 hours of engineering $2,640
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $4,224.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2023-30585 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2023-30585 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data