The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-42235

CVE-2026-42235: N8n Workflow Automation XSS Vulnerability

CVE-2026-42235 is a cross-site scripting flaw in n8n workflow automation that allows attackers to execute malicious scripts through OAuth client names. This post covers its technical details, affected versions, and patches.

Published: May 7, 2026

CVE-2026-42235 Overview

CVE-2026-42235 is a stored cross-site scripting (XSS) vulnerability in n8n, an open source workflow automation platform. An unauthenticated attacker can register a malicious Model Context Protocol (MCP) OAuth client with a crafted client_name. When a victim authorizes the OAuth consent dialog and a second user later revokes that access, a toast notification renders the injected script. Clicking the link executes arbitrary JavaScript in the victim's authenticated n8n session. The flaw is tracked under [CWE-79] and was patched in versions 1.123.32, 2.17.4, and 2.18.1.

Critical Impact

Successful exploitation enables credential and session token theft, workflow manipulation, and privilege escalation within the n8n application.

Affected Products

  • n8n Enterprise versions prior to 1.123.32
  • n8n Enterprise versions prior to 2.17.4
  • n8n Enterprise version 2.18.0 (fixed in 2.18.1)

Discovery Timeline

  • 2026-05-04 - CVE-2026-42235 published to the National Vulnerability Database
  • 2026-05-06 - Last updated in NVD database

Technical Details for CVE-2026-42235

Vulnerability Analysis

The vulnerability resides in the OAuth client registration flow used by n8n's MCP integration. The client_name field accepted during unauthenticated client registration is not sanitized before being rendered in downstream user interface components. Specifically, when an administrator revokes a previously authorized OAuth client, the application surfaces a toast notification containing the attacker-controlled client_name. The notification renders the value without proper output encoding, allowing embedded HTML and JavaScript payloads to execute in the browser context of the authenticated user.

Because the payload executes inside an active n8n session, an attacker can read session tokens, exfiltrate stored credentials used by workflows, modify or create automation workflows, and escalate privileges if the affected user is an administrator. The attack chain requires user interaction, but the trigger occurs during a routine administrative cleanup task.

Root Cause

The root cause is improper neutralization of user-supplied input during web page generation, classified under [CWE-79]. The OAuth dynamic client registration endpoint accepts unauthenticated input and persists the client_name field. The frontend toast component renders that string as HTML rather than as an inert text node, breaking the trust boundary between unauthenticated input and authenticated user output.

Attack Vector

The attack is network-based and requires no prior authentication to plant the payload. An attacker registers an OAuth client whose client_name contains an HTML anchor tag with a JavaScript handler. A user with consent rights authorizes the client. When a second user revokes the authorization, the malicious link appears inside a toast notification. Activating the link executes the script in the victim's n8n origin, granting the attacker access to the victim's session.

No public proof-of-concept code is available. Refer to the GitHub Security Advisory GHSA-537j-gqpc-p7fq for vendor-confirmed technical details.

Detection Methods for CVE-2026-42235

Indicators of Compromise

  • OAuth client registrations where client_name contains HTML tags, javascript: URIs, or event handler attributes such as onerror or onclick.
  • Unexpected outbound requests from authenticated user browsers shortly after OAuth consent or revocation actions.
  • New or modified n8n workflows, credentials, or API keys created without a corresponding administrator action.

Detection Strategies

  • Inspect the n8n database table storing OAuth clients and alert on client_name values containing <, >, ", or scheme prefixes like javascript:.
  • Review reverse proxy and application logs for POST requests to the MCP OAuth dynamic registration endpoint originating from unauthenticated sources.
  • Correlate session token reuse from unusual IP addresses with prior OAuth consent or revocation events in the n8n audit log.

Monitoring Recommendations

  • Forward n8n application and audit logs to a centralized SIEM and alert on OAuth client lifecycle events.
  • Monitor for browser-based anomalies such as unexpected fetches to /rest/credentials or /rest/workflows immediately after admin UI actions.
  • Track administrative account activity for unauthorized workflow changes or credential exports.

How to Mitigate CVE-2026-42235

Immediate Actions Required

  • Upgrade n8n to version 1.123.32, 2.17.4, or 2.18.1 or later as appropriate for your release branch.
  • Audit the OAuth client registry and delete any clients with suspicious client_name values.
  • Rotate session secrets, API keys, and credentials stored in workflows if exploitation is suspected.

Patch Information

The maintainers fixed the vulnerability in n8n versions 1.123.32, 2.17.4, and 2.18.1 by sanitizing the client_name field before rendering it in toast notifications. Patch metadata and remediation guidance are available in the GitHub Security Advisory GHSA-537j-gqpc-p7fq.

Workarounds

  • Restrict network access to the MCP OAuth dynamic client registration endpoint until the upgrade is applied.
  • Disable the MCP OAuth integration if it is not in active use.
  • Instruct administrators to avoid clicking links in OAuth-related toast notifications until the patch is deployed.
bash
# Upgrade n8n via npm to a fixed release
npm install -g n8n@2.18.1

# Or pull the patched Docker image
docker pull n8nio/n8n:2.18.1
docker stop n8n && docker rm n8n
docker run -d --name n8n -p 5678:5678 n8nio/n8n:2.18.1

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeXSS

  • Vendor/TechN8n

  • SeverityHIGH

  • CVSS Score8.8

  • EPSS Probability0.07%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:L/SC:H/SI:H/SA:L/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityHigh
  • AvailabilityLow
  • CWE References
  • CWE-79
  • Vendor Resources
  • GitHub Security Advisory
  • Related CVEs
  • CVE-2026-33749: n8n Workflow Automation XSS Vulnerability

  • CVE-2026-27578: n8n Workflow Automation XSS Vulnerability

  • CVE-2026-25054: N8n Workflow Automation XSS Vulnerability

  • CVE-2026-25051: N8n Workflow Automation XSS Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English