Description
n8n before 1.123.64, 2.29.8, and 2.30.1 contains a TOCTOU race condition in the Git node's clone operation that allows authenticated users to bypass path restrictions by swapping a directory for a symlink after the path is validated but before the clone runs. This lets an attacker plant a crafted repository in the community node directory, which n8n loads as a custom node on the next restart, executing arbitrary JavaScript on the server. Both self-hosted and cloud instances are affected.
Published: 2026-07-22
Score: 8.9 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

A TOCTOU race condition in n8n’s Git node clone operation allows an authenticated user to bypass path validation by swapping a directory for a symlink after validation but before the clone is executed. The attacker can place a crafted Git repository in the community node directory; when n8n restarts it loads that repository as a custom node and runs arbitrary JavaScript on the server. This results in full remote code execution within the n8n process.

Affected Systems

The vulnerability affects the n8n workflow automation platform, specifically versions before 1.123.64, as well as 2.29.8 and 2.30.1. Both self‑hosted and cloud‑hosted deployments of these versions are impacted. The affected vendor is n8n-io and the product is n8n.

Risk and Exploitability

The bug carries a CVSS score of 8.9, indicating high severity. The EPSS score of <1% suggests that the probability of exploitation is currently very low, although the vulnerability is not listed in the CISA KEV catalog. Nevertheless, the attack requires an authenticated user with write access to the community node directory. Once authenticated, the attacker can perform the TOCTOU race by replacing a directory with a symlink, inject a malicious repository, and have it loaded as a custom node upon n8n restart, causing arbitrary JavaScript execution on the server.

Generated by OpenCVE AI on August 3, 2026 at 23:57 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade n8n to version 1.123.64 or later, including the subsequent 2.29.x and 2.30.x releases, which fix the race condition.
  • If an upgrade cannot be applied immediately, remove write permissions from the community node directory or restrict the Git clone feature to a trusted set of users, thereby preventing the attacker from placing the malicious repository.
  • Monitor the community node directory for unexpected file system changes and verify that no unauthorized symlinks or custom node code has been injected before each restart.

Generated by OpenCVE AI on August 3, 2026 at 23:57 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-g3r5-9h93-4j2c n8n: Race Condition in Git Clone Node Allows Authenticated Users to Achieve Remote Code Execution
History

Wed, 22 Jul 2026 13:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Wed, 22 Jul 2026 11:45:00 +0000

Type Values Removed Values Added
Description n8n before 1.123.64, 2.29.8, and 2.30.1 contains a TOCTOU race condition in the Git node's clone operation that allows authenticated users to bypass path restrictions by swapping a directory for a symlink after the path is validated but before the clone runs. This lets an attacker plant a crafted repository in the community node directory, which n8n loads as a custom node on the next restart, executing arbitrary JavaScript on the server. Both self-hosted and cloud instances are affected.
Title n8n before 1.123.64 Remote Code Execution via Git Clone
First Time appeared N8n
N8n n8n
Weaknesses CWE-367
CPEs cpe:2.3:a:n8n:n8n:*:*:*:*:*:node.js:*:*
Vendors & Products N8n
N8n n8n
References
Metrics cvssV4_0

{'score': 8.9, 'vector': 'CVSS:4.0/AV:N/AC:H/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:L/SA:L'}


cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-07-22T12:22:51.683Z

Reserved: 2026-07-22T10:45:44.833Z

Link: CVE-2026-65598

cve-icon Vulnrichment

Updated: 2026-07-22T12:22:43.739Z

cve-icon NVD

Status : Analyzed

Published: 2026-07-22T12:18:20.037

Modified: 2026-07-27T19:18:06.673

Link: CVE-2026-65598

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-04T00:00:09Z

Weaknesses
  • CWE-367

    Time-of-check Time-of-use (TOCTOU) Race Condition