CVE-2026-56358: n8n has a Stored XSS Vulnerability in its Form Trigger
n8n's Form Trigger node has a stored cross-site scripting flaw: its CSS sanitization is flawed, so a user who can edit workflows can store a payload that runs for every visitor of the published form. Fixed in n8n 1.123.25 and 2.11.2.
Published Mar 27, 2026 · Updated Jul 20, 2026 · Analysis Nov 7, 2026
What an attacker can do
The Form Trigger node lets a workflow author supply custom styling. The sanitization of that CSS does not block everything dangerous. An attacker with permission to create or modify workflows stores a payload in the form, and it runs in the browser of everyone who opens the published form.
Victims need no targeted interaction; opening the form is enough. n8n's Content Security Policy blocks direct theft of session cookies, but it does not stop script from running or from changing where the form submits. The attacker can hijack submissions and run phishing flows on a page that looks trusted.
The CVSS 4.0 score is 5.1, with low confidentiality and integrity impact. Teams most at risk publish forms to outsiders or let many people edit workflows.
Who is affected
n8n from 2.0.0-rc.0 up to but not including 2.11.2, and all versions below 1.123.25. Check:
npm ls n8nInstances with the Form Trigger node enabled and more than one workflow editor are exposed.
n8n
- Ecosystem
- npm
- Affected
- >= 2.0.0-rc.0, < 2.11.2
- Fixed in
- 2.11.2
- Check
npm ls n8n
n8n
- Ecosystem
- npm
- Affected
- < 1.123.25
- Fixed in
- 1.123.25
- Check
npm ls n8n
How to fix it
Upgrade to n8n 2.11.2 on the 2.x line or 1.123.25 on the 1.x line. The advisory also cites 2.12.0, a later release with the fix.
Workarounds that do not fully fix it: restrict workflow creation and editing to fully trusted users, or disable the node by adding n8n-nodes-base.formTrigger to the NODES_EXCLUDE environment variable.
How to tell if you were hit
Review Form Trigger nodes in your workflows for custom CSS containing unusual content, such as url() values, expressions or script-like strings. Check workflow edit history for changes by users who should not touch forms. Look at form pages for unexpected form action targets.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Impact
An authenticated user with permission to create or modify workflows could exploit a flaw in the Form Trigger node's CSS sanitization to store a cross-site scripting (XSS) payload. The injected script executes persistently for every visitor of the published form, enabling form submission hijacking and phishing. The existing Content Security Policy prevents direct n8n session cookie theft but does not prevent script execution or form action manipulation.
Patches
The issue has been fixed in n8n versions 2.12.0, 2.11.2, and 1.123.25. 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 Form Trigger node by adding
n8n-nodes-base.formTriggerto theNODES_EXCLUDEenvironment variable.
These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.
Credited to tr4ce-ju.
Questions
- Can CVE-2026-56358 steal n8n session cookies?
The advisory says the existing CSP blocks direct cookie theft. Script execution, submission hijacking and phishing remain possible.
- How do I mitigate without upgrading?
Limit who can edit workflows, or set NODES_EXCLUDE to include n8n-nodes-base.formTrigger. Neither fully remediates.
- Who can exploit it?
An authenticated user with permission to create or modify workflows. Visitors of the form are the victims.
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 entriesCVE-2026-86073
n8n: Per-Resource OAuth Consent Bypass via Unbound Refresh Token Resource Substitution
medium5.9Sep 10, 2026CVE-2026-86074
n8n: Instance AI Credential Setup Accepts Unvalidated Probe URL from Fetched Content
medium5.9Sep 10, 2026CVE-2026-86075
n8n: Unauthenticated Persistent Storage Exhaustion via OAuth Dynamic Client Registration Endpoint
high8.7Sep 10, 2026CVE-2026-86076
n8n: Expression Sandbox Escape via Class-Field Sanitizer Rebinding Can Lead to Code Execution
high8.7Sep 10, 2026CVE-2026-86077
n8n: Anonymous Approval-Gate Bypass via Reused resumeToken over the Chat WebSocket
medium6.3Sep 10, 2026CVE-2026-86078
n8n: Prototype Pollution via Workflow Structure Summary Can Lead to Denial of Service
medium6.0Sep 10, 2026
