Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…
EPSS 0.8%top 46%

CVE-2026-54753: CWE-749: Exposed Dangerous Method or Function in nrwl nx

0
Medium
Published: 07/31/2026 (07/31/2026, 16:50:24 UTC)
Source: CVE Database V5
Vendor/Project: nrwl
Product: nx

Description

## Summary The local HTTP server started by `nx graph` sent `Access-Control-Allow-Origin: *` on every response, letting any website a developer visited read the server's responses cross-origin — including the full project graph and the output of the `/help` endpoint, which runs a target's configured help command. The practical impact is typically **cross-origin information disclosure**, but can be arbitrary command injection in rare cases. ## Severity Exploitation requires the developer to be running `nx graph` and to visit an attacker page. Any execution beyond benign help commands also requires a malicious target to already be present in the workspace (see Details). ## Affected & Patched Versions Package: `nx` (npm). - **Affected:** `>= 17.0.4, < 22.7.2` and `>= 23.0.0-beta.0, < 23.0.0-beta.2` - **Patched:** `22.7.2`+ (backport) and `23.0.0` (first in `23.0.0-beta.2`) The wildcard CORS header was introduced in `17.0.4`; the `/help` execution endpoint in `19.4.0`. **The `21.x` line is not patched** — `21.x` users should upgrade to `22.7.2` or later. ## Details `nx graph` starts a local server (default `http://127.0.0.1:4211`). Before the fix, its request handler set a wildcard CORS header on every response: ```ts res.setHeader('Access-Control-Allow-Origin', '*'); ``` The `/help` endpoint runs a target's configured command: ```ts const command = target.metadata?.help?.command; return execSync(command, { cwd: target.options?.cwd ?? workspaceRoot }).toString(); ``` A `GET /help` is a CORS "simple request", so a malicious page could `fetch()` it with no preflight, and the wildcard header let the page read the result. This exposes the project graph (project names, file paths, dependencies, build configuration) and the output of any configured help command. The command is not attacker-controlled through the request — it comes from the workspace's project configuration, and first-party plugins (jest, vite, cypress) populate it with benign, read-only help commands. For `/help` to run anything malicious, a target carrying a malicious `help.command` must already exist in the project graph, which can only be introduced by **installing a malicious package** or by **altering the workspace's own code/configuration** — both of which already grant code execution independent of this flaw. The fix ([#35494](https://github.com/nrwl/nx/pull/35494)) removes the header; the browser's same-origin policy then blocks cross-origin reads. ## References - Fix: [nrwl/nx#35494](https://github.com/nrwl/nx/pull/35494) - Introduced: [nrwl/nx#20744](https://github.com/nrwl/nx/pull/20744) (CORS), [nrwl/nx#26629](https://github.com/nrwl/nx/pull/26629) (`/help`) ## Credits Thanks to Nozomu Sasaki (Paul) ([@morimori-dev](https://github.com/morimori-dev)) for finding and responsibly reporting this issue.

CVSS v3.1

Score 5.9medium

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

Affected software

Affected versions
>=17.0.4 <22.7.2

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/31/2026, 21:30:27 UTC

Technical Analysis

The vulnerability (CVE-2026-54753) in nrwl nx arises from the local HTTP server started by `nx graph` setting the `Access-Control-Allow-Origin: *` header on all responses, including the `/help` endpoint which runs a configured help command for a target. This allows any website a developer visits to perform cross-origin requests and read sensitive information such as the project graph and help command output. The help command executed is derived from the workspace configuration and is not attacker-controlled via the request, limiting the risk of arbitrary command execution to scenarios where a malicious target is already present in the workspace. The vulnerability was introduced in version 17.0.4 (CORS header) and 19.4.0 (`/help` endpoint). It is patched in 22.7.2 and 23.0.0 (starting from 23.0.0-beta.2). The fix removes the wildcard CORS header, enforcing same-origin policy and preventing cross-origin reads.

Potential Impact

The primary impact is cross-origin information disclosure, exposing the full project graph and help command outputs to any website visited by a developer running `nx graph`. This can leak project names, file paths, dependencies, and build configurations. Arbitrary command injection is theoretically possible but requires a malicious target to already exist in the workspace, which implies prior compromise or installation of malicious packages. There are no known exploits in the wild. The CVSS v3.1 base score is 5.9 (medium severity), reflecting network attack vector, high complexity, user interaction required, and high confidentiality impact with low integrity impact.

Mitigation Recommendations

A fix is available in nrwl nx versions 22.7.2 and later, and 23.0.0 and later (including 23.0.0-beta.2). Users running affected versions (>=17.0.4 <22.7.2 and >=23.0.0-beta.0 <23.0.0-beta.2) should upgrade to these patched versions to remove the wildcard CORS header and prevent cross-origin information disclosure. The vendor advisory confirms the fix and no additional mitigations are required beyond upgrading. The 21.x line is unpatched and should be upgraded as well.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-06-15T23:12:41.965Z
Cvss Version
3.1
State
PUBLISHED
Remediation Level
null

Threat ID: 6a3eca5d72d29f1837deddf1

Added to database: 06/26/2026, 18:52:13 UTC

Last enriched: 07/31/2026, 21:30:27 UTC

Last updated: 08/09/2026, 15:31:15 UTC

Views: 89

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses