/

CVE-2026-103249

Severity:

HIGH RISK

(7.6)

Stored DOM XSS (CWE-79) in n8n Resource Locator Dropdown

CVE-2026-103249

Deferred

Vulnerability type

Category:

Stored DOM Cross-Site Scripting

CWE:

CWE-79

Impact:

Arbitrary JavaScript Execution in the Editor Origin

Severity:

HIGH RISK

(7.6)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

n8n contains a stored DOM cross-site scripting vulnerability in Resource Locator parameter dropdown link handling. A workflow author can store a malicious script URL that may execute JavaScript in the editor origin when another user opens the dropdown and selects its external-link icon.

Affected context

The vulnerability occurs in n8n workflows that use Resource Locator parameters with dropdown links rendered in the editor. Risk exists when workflow content containing attacker-controlled link values is imported, shared, or opened by another user, and the user interacts with the affected external-link control.

Exploit preconditions

  • Attack surface: n8n workflow editor and Resource Locator parameter dropdown UI
  • Required access: Ability to create, modify, import, or share workflow content
  • Trigger point: Another user opens the affected node dropdown and clicks the external-link icon
  • Persistence condition: The malicious link value remains stored in the workflow and survives imports or sharing
  • Why exploitation is possible: The editor processes attacker-controlled URL data in a DOM context without adequately preventing script-capable schemes or unsafe navigation behavior

Why this happens

The underlying bug is insufficient validation and safe handling of user-controlled URLs rendered by the Resource Locator dropdown. A script-capable URL can persist in workflow data and reach a browser interaction path that evaluates or executes it in the n8n editor origin. This behavior maps to CWE-79: Improper Neutralization of Input During Web Page Generation, specifically stored DOM-based cross-site scripting.

Potential impact

  • An attacker-controlled script may execute in the victim's n8n editor context
  • The script could read or alter accessible workflow and application data
  • An attacker could perform actions available to the affected user's editor session
  • Sensitive information displayed in the editor could be exposed
  • Shared or imported workflows could enable repeated exposure across users

General mitigation guidance

Mitigation generally focuses on treating workflow URLs as untrusted data throughout storage, rendering, and interaction handling.

Common defensive patterns include:

  • Allowing only explicitly supported URL schemes and rejecting script-capable schemes
  • Applying context-appropriate output encoding and safe DOM APIs
  • Avoiding HTML interpretation or dynamic code execution for link handling
  • Separating display text from navigation targets and validating both independently
  • Requiring explicit trust boundaries for imported and shared workflows
  • Applying least privilege to editor sessions and limiting accessible data and actions
  • Using browser security controls such as a restrictive Content Security Policy where practical

How teams detect issues like this

Organizations can look for this class of issue through:

  • Static analysis rules identifying unsafe DOM sinks, dynamic URL assignment, and insufficient scheme validation
  • Code review checks for workflow data flowing into link, HTML, navigation, or event-handling paths
  • Tests covering imported and shared workflows with untrusted URL values
  • Policy enforcement that restricts accepted URL schemes at both validation and rendering boundaries
  • Monitoring workflow content and UI behavior for unexpected script-capable links

Automated security review tools may help identify risky source-to-sink flows, but should be complemented by focused browser and integration testing.

Sources

SourceLink
github.comgithub.com/n8n-io/n8n/security/advisories/GHSA-c2wp-6fgc-xjq4
vulncheck.comvulncheck.com/advisories/n8n-before-1.123.80-2.39.6-and-2.40.1-stored-dom-xss-via-resource-locator

Frequently asked

questions

It can be exploitable through workflow sharing or importing when an attacker can cause another user to open the affected workflow and interact with the Resource Locator dropdown.

The attacker generally needs a way to create or modify workflow content that the victim will receive or open. The victim's interaction with the affected control is also part of the trigger.

Treat all workflow-provided URLs as untrusted, permit only approved schemes, and ensure link rendering and navigation use safe, non-interpreting browser APIs.

Combine strict URL validation, context-aware output encoding, safe DOM manipulation, security-focused code review, and tests for imported or shared untrusted workflows.

Find out what's already
exploitable in your codebase.