AgentbeamBeta
AI agent vulnerability · n8n

CVE-2026-27578: n8n Vulnerable to Stored XSS via Various Nodes

highCVSS 4.0 8.5 · 3.1 5.4GHSA-2p9h-rqjw-gm92

Several n8n nodes (Form Trigger, Chat Trigger, Send & Wait, Webhook and Chat) let a workflow author inject script into pages that n8n renders. The script runs in the browser of anyone who opens the page, which enables session hijacking and account takeover. Fixed in n8n 1.123.22, 2.9.3 and 2.10.1.

Published Feb 25, 2026 · Updated Feb 27, 2026 · Analysis Nov 9, 2026

What an attacker can do

This is stored cross-site scripting (CWE-79 and CWE-80) found by several reporters, using a different technique in each node. A user with permission to create or modify workflows builds a workflow whose Form Trigger, Chat Trigger, Send & Wait, Webhook or Chat node outputs attacker-controlled HTML. n8n serves that page from its own origin.

Anyone who visits the page, including an admin who opens a form or chat link, runs the script with their n8n session. The script can call the n8n API as that user, read workflows and credential metadata, create API keys or accounts, and so take over the account. The advisory states session hijacking and account takeover as the result.

The attacker needs a low-privilege account with workflow edit rights and a victim who opens the page, which gives the CVSS 4.0 score of 8.5. The 3.1 vector scores lower, at 5.4. The advisory does not describe the injection technique for each node.

Who is affected

Affected npm n8n versions: below 1.123.22; 2.0.0 up to but not including 2.9.3; and 2.10.0 up to but not including 2.10.1. Instances where several people can edit workflows, or where form and chat pages are shared with other staff, are most exposed.

npm ls n8n
n8n --version

For Docker, check the image tag. The version is shown in the UI under Help, About.

n8n

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

n8n

Ecosystem
npm
Affected
>= 2.0.0, < 2.9.3
Fixed in
2.9.3
Check
npm ls n8n

n8n

Ecosystem
npm
Affected
>= 2.10.0, < 2.10.1
Fixed in
2.10.1
Check
npm ls n8n

How to fix it

Upgrade to n8n 1.123.22, 2.9.3 or 2.10.1, or later in your line:

npm install [email protected]

The fixes are in commits 062644ef, 1479aab2 and 9e5212ec. Temporary measures from the advisory, which it says do not fully remediate the risk: restrict workflow creation and editing to fully trusted users, and disable the Webhook node by adding n8n-nodes-base.webhook to NODES_EXCLUDE. The advisory gives no workaround for the other four nodes.

How to tell if you were hit

Review workflows that use the Form Trigger, Chat Trigger, Send & Wait, Webhook or Chat nodes. Look for fields that hold script tags, event handler attributes such as onerror=, javascript: URLs or heavily encoded HTML. Check who last edited them. In n8n audit data, look at actions by admins or owners shortly after they opened a form, chat or wait link: new API keys, new users, changed credentials or exports of workflows.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Impact

An authenticated user with permission to create or modify workflows could inject arbitrary scripts into pages rendered by the n8n application using different techniques on various nodes (Form Trigger node, Chat Trigger node, Send & Wait node, Webhook Node, and Chat Node). Scripts injected by a malicious workflow execute in the browser of any user who visits the affected page, enabling session hijacking and account takeover.

Patches

The issues have been fixed in n8n versions 2.10.1, 2.9.3, and 1.123.22. 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:

  • Limit workflow creation and editing permissions to fully trusted users only.
  • Disable the Webhook node by adding n8n-nodes-base.webhook to the NODES_EXCLUDE environment variable.

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

Credit

Reporters:

  • @ori-ron
  • @Aikido-Security
  • @nil340
  • Pawel Bednarz from the NATO Cyber Security Centre (NCSC)

Credited to ori-ron, Aikido-Security, nil340.

Questions

Which n8n nodes are affected by CVE-2026-27578?

The Form Trigger, Chat Trigger, Send & Wait, Webhook and Chat nodes. Each has a different injection technique, and the advisory does not give details.

Does the attacker need an account?

Yes. The attacker must be authenticated and allowed to create or modify workflows. A victim must then open the affected page.

Is disabling the Webhook node enough?

No. The advisory's only node-specific workaround is for Webhook, and it says the workarounds do not fully remediate the risk. Upgrade instead.

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