Description
n8n before 1.123.64, 2.x before 2.29.8, and before 2.30.1 contains a DOM-based cross-site scripting vulnerability in the HTML preview, which renders execution output into an iframe srcdoc without the sandbox attribute. A sanitizer bypass allows injected script to execute same-origin as the editor. When a victim opens the preview, the script can call authenticated APIs using the victim's session. An account with global:member privileges can exploit the issue.
Published: 2026-07-22
Score: 8.2 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

A DOM‑based cross‑site scripting flaw exists in the HTML preview feature of n8n. The preview renders execution output into an iframe srcdoc without a sandbox attribute, and a sanitizer bypass permits malicious JavaScript to be injected. The injected script runs in the same origin as the editor, so it can invoke authenticated APIs using the victim’s session. This can expose sensitive data or allow other actions that require the victim’s credentials.

Affected Systems

The flaw affects n8n platform releases prior to 1.123.64, the 2.x series before 2.29.8, and any release before 2.30.1. Users running these versions are vulnerable, and an account with global:member privileges can create the malicious content that triggers the preview.

Risk and Exploitability

The CVSS score of 8.2 indicates a high severity, while the EPSS score of less than 1% suggests that exploitation is currently considered unlikely. The vulnerability is not listed in CISA’s KEV catalog. Exploitation requires an authenticated user with global:member or higher privileges to supply malicious content that is later rendered in the preview. When a victim opens the preview, the unsandboxed iframe executes the injected script, giving it same‑origin access to the user’s session and authenticated API endpoints.

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

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to n8n 1.123.64 or later, or to a 2.x release 2.29.8 or later, or to 2.30.1 or later
  • If an upgrade is not immediately possible, disable the HTML preview feature or restrict preview access to non‑privileged users to prevent unsandboxed iframe execution
  • Apply additional client‑side sanitization or enforce the sandbox attribute on custom‑configured iframes as a temporary workaround

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

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-p3rg-hrf9-w9gj n8n: DOM-Based XSS via Unsandboxed iframe srcdoc in HTML Preview
History

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

Type Values Removed Values Added
Metrics ssvc

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


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

Type Values Removed Values Added
Description n8n before 1.123.64, 2.x before 2.29.8, and before 2.30.1 contains a DOM-based cross-site scripting vulnerability in the HTML preview, which renders execution output into an iframe srcdoc without the sandbox attribute. A sanitizer bypass allows injected script to execute same-origin as the editor. When a victim opens the preview, the script can call authenticated APIs using the victim's session. An account with global:member privileges can exploit the issue.
Title n8n before 1.123.64 DOM-Based XSS via Unsandboxed iframe
First Time appeared N8n
N8n n8n
Weaknesses CWE-79
CPEs cpe:2.3:a:n8n:n8n:*:*:*:*:*:node.js:*:*
Vendors & Products N8n
N8n n8n
References
Metrics cvssV4_0

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


cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-07-22T15:58:12.717Z

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

Link: CVE-2026-65597

cve-icon Vulnrichment

Updated: 2026-07-22T15:58:04.936Z

cve-icon NVD

Status : Analyzed

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

Modified: 2026-07-27T19:15:45.820

Link: CVE-2026-65597

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

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

Weaknesses
  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')