NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · n8n

GHSA-rcv6-pvrj-4xcg: n8n: Authenticated code execution in the n8n Git node

highCVSS 4.0 8.7

Under the default git security settings, the n8n Git node can be made to run git hooks from a crafted local repository. A user who can create and run workflows gets arbitrary command execution as the n8n process user. Self-hosted and cloud instances are affected. Fixed in n8n 1.123.67, 2.31.5 and 2.32.1.

Published Jul 22, 2026 · Analysis Oct 25, 2026

What an attacker can do

Git runs hook scripts, such as pre-commit or post-checkout, from a repository's hooks directory. An attacker with workflow create and execute rights stages a crafted local repository and then uses the Git node on it. Under the default git security settings, git runs the planted hooks (CWE-78, OS command injection). Those commands run as the user of the n8n process.

The attacker needs only an authenticated account that can build and run workflows with the Git node. No user interaction is needed. The CVSS 4.0 vector rates confidentiality, integrity and availability impact as high.

The outcome is full control of the n8n service account on the host. That includes the credentials n8n stores, environment variables, and whatever network the host can reach. On a shared instance, an ordinary editor becomes effectively an administrator of the host. The advisory gives no payload and no proof of concept.

Who is affected

Affected: n8n below 1.123.67 on the 1.x line, 2.0.0-rc.0 up to but not including 2.31.5, and 2.32.0. Any instance where users other than fully trusted admins can run workflows that use the Git node is exposed, including cloud instances.

Check the version:

npm ls n8n

For Docker, check the image tag or the version in the UI.

n8n

Ecosystem
npm
Affected
< 1.123.67
Fixed in
1.123.67
Check
npm ls n8n

n8n

Ecosystem
npm
Affected
>= 2.32.0, < 2.32.1
Fixed in
2.32.1
Check
npm ls n8n

n8n

Ecosystem
npm
Affected
>= 2.0.0-rc.0, < 2.31.5
Fixed in
2.31.5
Check
npm ls n8n

How to fix it

Upgrade to n8n 1.123.67, 2.31.5 or 2.32.1, or later. For an npm install, run npm install [email protected].

Temporary mitigations from the advisory, none of which fully remove the risk:

  • Restrict instance access to fully trusted users.
  • Add n8n-nodes-base.git to the NODES_EXCLUDE environment variable to disable the Git node.
  • Restrict network egress from the n8n instance to limit what code execution can do.

How to tell if you were hit

Look in the n8n workspace for git repositories with executable files in a hooks directory, or hooks that are not the usual .sample files. Review workflows and execution history for Git node runs by non-admin users. Watch for child processes of the n8n service that you do not expect, such as shells, curl or wget, and for outbound connections from the host that your workflows do not explain. If you find any, treat the host and its stored credentials as compromised.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Impact

Authenticated n8n users with rights to create and execute workflows could achieve code execution on the n8n host. Using the Git node, under the default git security settings, by staging a crafted local repository, an attacker could cause git to run hooks, executing arbitrary commands as the n8n process user.

Both self-hosted and cloud instances are affected where authenticated users can create and execute workflows using the Git node.

Patches

The issue has been fixed in n8n versions 1.123.67, 2.31.5, and 2.32.1. Users should upgrade to one of these versions or later to remediate the vulnerability.

Workarounds

If upgrading is not immediately possible, administrators should consider the following temporary mitigations:

  • Restrict n8n instance access to fully trusted users only.
  • Disable the Git node by adding n8n-nodes-base.git to the NODES_EXCLUDE environment variable.
  • Restrict network egress from the n8n instance to limit the impact of arbitrary code execution.

These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.

Credited to simonkoeck.

Questions

Who can exploit GHSA-rcv6-pvrj-4xcg?

An authenticated n8n user who can create and execute workflows that use the Git node. The CVSS vector lists low privileges and no user interaction.

Does it need non-default settings?

No. The advisory says the attack works under the default git security settings.

How can I mitigate it before upgrading?

Add n8n-nodes-base.git to NODES_EXCLUDE, limit access to trusted users and restrict egress. The advisory says these do not fully remediate the risk.

Which versions are patched?

n8n 1.123.67, 2.31.5 and 2.32.1, or later.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More n8n vulnerabilities

All n8n entries