Skip to main content

SunEditor EUVDEUVD-2026-136757

| CVE-2026-137557 MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2026-11-26 VulnCheck
5.1
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate as low-privileged content author
  2. Delivery
    Store pre with entity-encoded language- class
  3. Exploit
    Victim opens saved content in editor
  4. Execution
    Hover triggers innerHTML hover-button sink
  5. Impact
    Execute script in host page, hijack victim session

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires the codeBlock plugin (part of SunEditor's bundled default plugin set) with a non-empty language list, which is the default. The application must load one user's saved editor content into another user's editor via setContents, the initial textarea value, paste, or html.insert - i.e. shared-document, CMS, or admin-moderation workflows where attacker content reaches a victim. The attacker needs the ability to store editor content (PR:L), and the victim must hover the mouse over the rendered code block (UI:P) for the innerHTML sink to fire. Payload is an entity-encoded value in a language- class on a <pre> (or <pre><code>) element that survives html.clean() because the class allowlist permits ^language- and the on-handler regex requires whitespace before 'on'. Affected versions are 3.0.0 through 3.4.2. Limiting factors: integrators who also perform strict server-side sanitization with a tight class allowlist may be unaffected (per the advisory), and exploitation depends on a victim hover rather than mere page load.

Impact

This is a genuine but mid-tier priority, best described as a real-but-conditional stored XSS rather than an emergency. The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:L/UI:P) and 5.1 'medium' base score tell a consistent story: network-reachable and low-complexity, but gated by PR:L (the attacker must be able to store editor content, i.e. an authenticated or otherwise content-contributing user) and UI:P (the victim must passively interact - here, hover over the code block). The impact metrics VC:N/VI:N/VA:N with SC:L/SI:L reflect that nothing on the editor component itself is harmed; instead script executes in the host page (a subsequent-system/scope effect), which the advisory confirms by noting the hover controller lives in the main document even in iframe mode. No EPSS score and no KEV listing are present in the input, so there is no evidence of active or automatable exploitation; the vuln.today Decision label is 'this_month', not act_now or emergency, which aligns with the medium severity. A detailed reproduction with a working-looking payload is published in the GHSA advisory, but the advisory itself states it is static analysis only and was not run in a browser, so a public PoC reference exists but is not verified as working exploit code. Net: prioritize patching within a normal monthly cycle, higher if you run a multi-user workflow (shared docs, CMS, admin moderation) where one user's content is opened in another user's editor.

Exploit ScenarioDerived

An authenticated low-privileged user (PR:L) saves editor content containing a <pre> code block whose language- class is entity-encoded, e.g. class="language-&lt;img/src='x'/onerror='alert(document.domain)'&gt;". When a second user - such as an admin moderator or another contributor in a shared-document/CMS workflow - later opens that content and moves the mouse over the code block (UI:P), the browser decodes the class into the hover button via innerHTML and the injected handler runs in the host page origin, enabling session/token theft or actions as the victim. A public PoC reference exists in the GHSA advisory; it is not verified as working exploit code (static analysis only).

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 26, 2026

Stored cross-site scripting in the SunEditor WYSIWYG editor's codeBlock plugin (versions 3.0.0 through 3.4.2) lets an attacker who can save editor content plant a code block whose language value decodes to HTML markup, which is then written through innerHTML into the language hover button and executed when a victim moves the mouse over the block. The payload survives the built-in html.clean() sanitizer because it is entity-encoded in a language- class attribute: the class allowlist permits any token beginning with 'language-', and the on-handler filter only strips names preceded by whitespace, so no raw '>' or ' on' ever appears in the raw string. Successful exploitation is conditional on a workflow where one user's stored content is later loaded into another user's editor (shared documents, CMS editing, admin moderation) plus a victim hover rather than mere page load; the vendor released 3.4.3 to address it, and no confirmed public exploit code has been identified at time of analysis, although the upstream advisory publishes step-by-step reproduction payloads.

RemediationAI

Upgrade to SunEditor 3.4.3 or later; the vendor-released patch is 3.4.3, per the GHSA advisory at https://github.com/JiHong88/suneditor/security/advisories/GHSA-j4jp-7r3h-rf28, and the npm package lists the fix as 3.4.3 for the >= 3.0.0 <= 3.4.2 range. The advisory's suggested code-level remediation is to treat the language name as text rather than HTML - build the hover-button spans with createElement and set the label with textContent, escape currentLang before it reaches SelectMenu.create(), restrict accepted language identifiers in #getPreLang, #setLang and html.#unwrapPreCode to a pattern such as /^[A-Za-z0-9_+#.-]+$/, and tighten the sanitizer's class allowlist entry from ^language- to ^language-[\w+#.-]+$. Where an immediate upgrade is not possible, two compensating controls are available, each with trade-offs: (1) disable the codeBlock plugin or ship it with an empty language list, which removes the hover button and the innerHTML sink but also removes syntax-highlighted code blocks and the language selector from the editor; (2) add strict server-side sanitization on stored editor content with a tight class allowlist that rejects entity-encoded markup in language- values - per the advisory, integrators already doing this may be unaffected - at the cost of a second sanitization layer that must be kept in sync with the editor's own output and may strip legitimate class names. Neither workaround removes the underlying bug, and both leave already-stored malicious content in place unless existing records are re-sanitized.

Affected VersionsENISA

suneditor 3.0.0 <3.4.3

Affected Packages

euvd suneditor fix: 3.4.3

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

SunEditor is a JavaScript WYSIWYG editor distributed on npm as the 'suneditor' package and identified in CPE data as cpe:2.3:a:jihong88:suneditor. The flaw is CWE-79 (improper neutralization of input during web page generation), specifically a sanitizer-bypass leading to a DOM-based DOM sink. In the codeBlock plugin, #getPreLang reads the language identifier straight out of the content itself using className.match(/language-(\S+)/) on the <pre> element, and that value is then concatenated into the hover controller's button via innerHTML (codeBlock.js:304); the same value also reaches SelectMenu.create() as a menu label, where <li> markup is assembled from strings. Sanitization fails on two fronts: the default class allowlist in src/core/schema/options.js includes the pattern ^language-, and the attribute whitelist accepts class, while the on-handler regex used by #CleanElements requires whitespace before 'on' and therefore never sees the entity-encoded '&lt;img/src=x/onerror=...&gt;' variant, which also carries no raw '>'. The browser subsequently decodes the entities into className, and the decoded markup is parsed as HTML in the host page origin. The <pre><code class="language-..."> form is equally affected because #unwrapPreCode copies the matched class onto the <pre>. The hover UI is enabled by default whenever the language list (DEFAULT_LANGS) is non-empty, which is the shipped configuration, and the hover controller lives in the main document even when the editor runs in iframe mode.

Know when Suneditor gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 5.1 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
vuln.today AI 5.4 MEDIUM

Stored XSS needs an authenticated content author (PR:L) and a victim hover (UI:R); decoded markup executes in the host page beyond the editor (S:C), yielding limited C/I and no availability impact.

3.1 AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
4.0 AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
Passive
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
Low
Subsequent system: Integrity
Low
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Nov 26, 2026 - 17:02 EUVD

DescriptionCVE.org

SunEditor from 3.0.0 before 3.4.3 contains a stored cross-site scripting vulnerability in the codeBlock plugin that allows attackers to inject script via entity-encoded pre language class values. Attackers can store content whose language- class decodes to HTML written via innerHTML into the hover button, executing script when victims hover over the block.

Threat Intelligence Overview

EPSS Score
0.3%
Top 85% exploitable
Prevalence
Medium
popular open-source WYSIWYG editor (npm suneditor) embedded in many web apps
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

26
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy