Jun 9, 2026·5 min read·40 visits
TinyMCE versions prior to 6.8.1 failed to sandbox pasted/inserted iframes or convert risky object and embed tags, allowing attackers to execute arbitrary scripts in the application context via client-side payloads.
CVE-2024-29203 identifies a cross-site scripting (XSS) vulnerability in the content ingestion and parsing mechanics of TinyMCE rich text editor. Due to a failure to enforce sandbox attributes on dynamic iframe elements and safely handle legacy embed objects, unauthenticated attackers can inject malicious elements that execute scripts within the context of the parent application session.
TinyMCE is an open-source, web-based rich text editor widely integrated into content management systems, email clients, and collaboration platforms. To allow users to draft formatted text, media, and other embedded visual objects, the editor processes complex HTML documents through an internal parsing subsystem. This ingestion layer relies on a DOM parser to filter input markup, ensuring it conforms to configured schema specifications and security constraints.\n\nThe primary attack surface resides within elements that permit content embedding, specifically <iframe>, <object>, and <embed> nodes. Historically, these tags were accepted as long as they met the standard dimension and structure constraints defined in the schema. This design did not restrict nested capabilities or isolate the embedded frames from the execution scope of the primary application.\n\nUnder default configurations in versions prior to 6.8.1, the editor did not apply restrictive isolation attributes such as sandbox to <iframe> elements. This programmatic gap allowed attackers to introduce scripting elements that could execute within the DOM tree of the parent web application, compromising client-side security controls.
The core of the vulnerability lies in the parser's passive processing of embedded document nodes. When TinyMCE parses imported markup (via paste actions or programmatically through APIs like setContent()), the DomParser validates elements against an allowed-list schema. If the schema permitted iframes, the parser constructed the DOM node without inspecting or rewriting its security-sensitive attributes.\n\nUnsandboxed iframes represent a severe risk in browser environments. If an iframe points to an external source or defines inline script using schemes like javascript: or data:text/html, the browser executes the script in the origin context of the parent frame unless restricted. This allows direct programmatic read-and-write access to cookie jars, session tokens, and document structures of the host application.\n\nFurthermore, the parser accepted legacy <object> and <embed> tags. These legacy elements were designed to launch binary browser extensions (including Java, Adobe Flash, and various PDF viewers). In modern browsers, these elements can execute complex interactions or force the browser to process parameter arrays that trigger unauthorized behaviors, bypassing standard script restrictions.\n\nThe failure to automatically sanitize these elements or transform them into safe alternatives meant that malicious actors could manipulate the active editor environment. Because these settings defaulted to unmitigated states in all versions of TinyMCE 6.x, users hosting default instances were left exposed.
The patch with commit ID bcdea2ad14e3c2cea40743fb48c63bba067ae6d1 mitigates these risks by adding configuration-controlled filters. These filters are defined within the ParserFilters.ts and Options.ts modules. Two core configurations were introduced: sandbox_iframes and convert_unsafe_embeds.\n\nThe options registration assigns a boolean validation processor to both configurations, ensuring that administrators can explicitly manage parsing policies. In version 6.8.1, these default to false for backwards compatibility. In version 7.0.0, the default for sandbox_iframes was updated to true to ensure out-of-the-box protection.\n\nThe core processing logic added to ParserFilters.ts utilizes the addNodeFilter API. When parsing runs, nodes matching object or embed are captured and routed through a transformation filter. This filter converts the legacy tags into safe semantic counterparts (<img>, <video>, <audio>), or sandboxed <iframe> tags if the MIME type cannot be matched safely:\n\ntypescript\n// Pre-patch: Object and embed tags parsed directly without validation or type conversion\n// Post-patch: Nodes are dynamically transformed into safe HTML counterparts\nif (settings.convert_unsafe_embeds) {\n parser.addNodeFilter('object,embed', (nodes) => Arr.each(nodes, (node) => {\n node.replace(\n createSafeEmbed(\n node.attr('type'),\n node.name === 'object' ? node.attr('data') : node.attr('src'),\n node.attr('width'),\n node.attr('height'),\n settings.sandbox_iframes\n ));\n }));\n}\n\n\nSimilarly, if sandbox_iframes is enabled, any iframe node is parsed, and the parser forcibly appends the sandbox="" attribute. This is done via:\n\ntypescript\nif (settings.sandbox_iframes) {\n parser.addNodeFilter('iframe', (nodes) => Arr.each(nodes, (node) => node.attr('sandbox', '')));\n}\n\n\nThe integration of the sandbox="" attribute restricts the frame's execution contexts. Even if the source points to a script or a data URI, the browser blocks form submissions, script execution, popups, and forces a unique origin constraint. This successfully stops execution of client-side payloads.
To execute this attack, a malicious actor must deliver a payload into the editor interface. This is typically achieved via clipboard paste operations or through data sources processed by the host application. A targeted user needs to interact with the editor, such as viewing a document that renders the input content.\n\nConsider a scenario where the application accepts markdown or pasted HTML. An attacker can construct a payload containing a script within an iframe:\n\nhtml\n<iframe src="javascript:alert(parent.document.cookie)"></iframe>\n\n\nOr they can utilize a data URI scheme inside an iframe, which runs active script content:\n\nhtml\n<iframe src="data:text/html,<script>alert(1)</script>"></iframe>\n\n\nAdditionally, legacy <object> and <embed> tags can be targeted to bypass basic string-filtering web application firewalls (WAFs):\n\nhtml\n<object data="javascript:alert(document.domain)"></object>\n\n\nWhen pasted, the browser or the editor's copy-paste handler processes the clipboard content. TinyMCE's parser parses the tags and appends them to the active editor workspace. Because the sandbox and conversion controls are absent, the browser processes the new elements and evaluates the JavaScript, executing the payload in the context of the user's active session.
The most effective resolution is upgrading the TinyMCE library to at least version 6.8.1. However, because version 6.x defaults the defensive options to false, the patch will remain inactive unless administrators explicitly declare the settings in their application code.\n\nTo configure the defenses in a 6.x deployment, developers must set sandbox_iframes and convert_unsafe_embeds to true during the initialization phase:\n\njavascript\ntinymce.init({\n selector: 'textarea#editor',\n sandbox_iframes: true,\n convert_unsafe_embeds: true\n});\n\n\nUpgrading to version 7.x is recommended for long-term security. TinyMCE 7.0.0 secures the editor out of the box by setting sandbox_iframes to true by default, eliminating the risk of misconfiguration.\n\nFor verification, security teams can test the active instance by executing tinymce.activeEditor.getContent() after inserting a standard <iframe> or <object>. If the mitigation is functioning, the retrieved content must contain the sandbox="" attribute on all iframe tags, and legacy tags should be converted to safe semantic elements.
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:N| Product | Affected Versions | Fixed Version |
|---|---|---|
TinyMCE Tiny Technologies | < 6.8.1 | 6.8.1 |
TinyMCE Tiny Technologies | >= 6.8.2, < 7.0.0 | 7.0.0 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-79 (Improper Neutralization of Input During Web Page Generation) |
| Attack Vector | Network |
| CVSS v3.1 Score | 4.3 (Medium Severity) |
| EPSS Score | 0.01605 (Percentile: 82.11%) |
| Exploit Status | PoC / Code-level understanding available |
| CISA KEV Status | Not Listed |
| Ransomware Association | No |
The software does not neutralize or incorrectly neutralizes user-controlled input before it is placed in output that is used as a web page that is served to other users.
A critical Server-Side Request Forgery (SSRF) bypass vulnerability exists in CodeWhale before version 0.8.64 (and version 0.8.41 in the 0.8.x branch) due to a Time-of-Check to Time-of-Use (TOCTOU) bug in its DNS pre-flight validation mechanism. By returning a temporary resolution failure during validation and subsequently resolving to restricted IPs during HTTP execution, attackers can bypass security rules.
An argument injection vulnerability in CodeWhale (CVE-2026-75912 / GHSA-c6mw-8xh8-gpq6) allows unauthenticated remote attackers to execute arbitrary option commands on the git binary. By passing malicious command-line flags inside git_blame and git_show tool helper functions, an attacker can bypass typical access controls to read arbitrary local system files via the underlying git process.
SurrealDB prior to version 3.2.0 is vulnerable to an authorization bypass where authenticated users can invoke custom API endpoints belonging to other tenants. This cross-tenant data access occurs because the system fails to validate authorization scope boundaries against request-supplied namespace and database identifiers before executing scripts with elevated definer's rights.
An incorrect authorization vulnerability (CWE-863) in SurrealDB allows authenticated, low-privileged users to execute unauthorized state-modifying queries. This occurs because the database disabled permissions during evaluation of custom PERMISSIONS WHERE predicates to prevent infinite recursion.
SiYuan before v3.7.4 fails to enforce publish-access filters on five filetree path-resolution endpoints, allowing unauthenticated attackers to reconstruct private directory layouts and map document structures.
Prior to version v3.7.4, the SiYuan personal knowledge management system contained a critical logical authorization vulnerability within its database view rendering component. The flaws allowed unauthenticated remote attackers to bypass publish-access filters on databases, exposing sensitive Relation and Rollup cell contents belonging to private or password-protected repositories.