Where
-Infinity
0

Vendor Risk Score

See how suneditor compares to other vendors in security performance

View Risk Score →
Severity
5.3
XSS
AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N/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

SunEditor from 3.0.0 before 3.4.0 contains a stored cross-site scripting vulnerability in html.clean() that rebuilds iframes from data-se-iframe-holder-attrs JSON without filtering srcdoc or uppercase SRC keys. Attackers can inject crafted HTML through paste, html.set, or html.insert to execute script in the host page origin when victims load or paste the content.

First published (updated )
Severity
5.3
XSS
AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

SunEditor from 3.0.0 before 3.4.0 contains a stored cross-site scripting vulnerability in html.clean() that rebuilds iframes from data-se-iframe-holder-attrs JSON without filtering srcdoc or uppercase SRC keys. Attackers can inject crafted HTML through paste, html.set, or html.insert to execute script in the host page origin when victims load or paste the content.

First published (updated )
Severity
5.3
XSS
AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability in the FileUpload plugin create() method that assigns server-returned file names to innerHTML without escaping. Attackers can upload files with HTML-laden names that bypass html.clean() and execute JavaScript in victims' browsers when content or gallery items load, enabling session theft.

First published (updated )
Severity
9.3
XSS
AV:N/AC:L/AT:N/PR:N/UI:A/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N/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

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability because the html.clean() sanitizer's normalizeURL() function decodes named entities like : to an empty string. Attackers can inject href values such as javascript: that pass the isSafeURL() check but are decoded by browsers, executing JavaScript when victims click stored links.

First published (updated )
Severity
8.3
XSS
AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:L/A:N

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability in ModalAnchorEditor's #createBookmarkList, which inserts entity-decoded h1-h6 header textContent into the bookmark list via innerHTML without escaping. Attackers can store HTML-encoded payloads in editor headers that execute JavaScript when a victim opens the link modal and types # in the URL input.

First published (updated )
Severity
9.3
XSS
AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N/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

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability in the DocumentType constructor that injects header textContent into innerHTML without HTML escaping. Attackers can store entity-encoded HTML in h1-h6 headers that executes JavaScript when editors using document:header mode initialize, enabling session cookie theft.

First published (updated )
Severity
8.3
XSS
AV:N/AC:L/AT:N/PR:L/UI:P/VC:H/VI:L/VA:N/SC:H/SI:L/SA:N

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability in ModalAnchorEditor's #createBookmarkList, which inserts entity-decoded h1-h6 header textContent into the bookmark list via innerHTML without escaping. Attackers can store HTML-encoded payloads in editor headers that execute JavaScript when a victim opens the link modal and types # in the URL input.

First published (updated )
Severity
5.3
XSS
AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability in the FileUpload plugin create() method that assigns server-returned file names to innerHTML without escaping. Attackers can upload files with HTML-laden names that bypass html.clean() and execute JavaScript in victims' browsers when content or gallery items load, enabling session theft.

First published (updated )
Severity
9.3
XSS
AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N

SunEditor before 3.4.0 contains a stored cross-site scripting vulnerability in the DocumentType constructor that injects header textContent into innerHTML without HTML escaping. Attackers can store entity-encoded HTML in h1-h6 headers that executes JavaScript when editors using document:header mode initialize, enabling session cookie theft.

First published (updated )
Severity
10
XSS
AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H

Summary

SUNEDITOR v2.47.10 appears to allow JavaScript execution through crafted namespaced HTML elements.

The sanitization logic does not fully remove executable event-handler attributes from certain custom/namespaced tags. As a result, an attacker may be able to inject HTML content that executes JavaScript when the rendered element is interacted with.

This behavior was observed after the changes introduced in this commit:

https://github.com/JiHong88/suneditor/commit/9ed405fb0de676e56cd0e6a13c19c103ad5948d3

---

Affected Version

Confirmed vulnerable:

SUNEDITOR =< 2.47.10

Potentially affected:

Previous versions, if the same sanitization logic is still present

---

Proof of Concept

The following payload preserves an executable event handler:

html <a:b src="/x"><iframe src=javascript:alert(1)></iframe></a:b>

<p><a:b src="/x" onclick="document.body.style.background='red'">click</a:b></p>

Simplified PoC:

html <a:b src="/x" onclick="console.log('XSS:',document.domain,document.cookie)">click</a:b>

html <p><a:b src="/x" onmouseover="alert('XSS — '+document.domain)">📎 Click here for solutions</a:b></p> ---

Steps to Reproduce

1. Open SUNEDITOR using version 2.47.10. 2. Insert the payload above into the editor. 3. Save or render the generated content. 4. Click the generated element. 5. Observe that JavaScript is executed.

---

Impact

This may allow an attacker to inject arbitrary JavaScript into rendered editor content.

Depending on how SUNEDITOR is integrated into an application, this could lead to:

Stored XSS DOM manipulation Session theft Credential theft Account takeover actions performed in the victim’s browser context

---

Technical Details

The issue appears to be related to incomplete handling of namespaced/custom HTML elements such as:

html <a:b>

Event-handler attributes such as onclick can remain attached to these crafted elements and execute when interacted with.

This suggests that the sanitization process may not consistently normalize and validate custom or namespaced elements before applying attribute filtering.

---

Suggested Remediation

Possible mitigations include:

Normalize DOM elements before sanitization. Explicitly reject or unwrap unknown/custom/namespaced tags. Strip all event-handler attributes from all elements, including unknown/custom elements. Re-validate sanitized output after browser DOM parsing. Add regression tests for namespaced/custom tag payloads.

---

1 / 2
Source: GitHub
First published (updated )

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203