CVE-2026-66843 Details
Description
Inclusion of Functionality from Untrusted Control Sphere vulnerability in the HTML5 scrubber in rrrene html_sanitize_ex allows a remote attacker to load a document of their choosing into a trusted page via the data attribute of an <object> element in sanitized HTML. object is the one URI-bearing element in lib/html_sanitize_ex/scrubber/html5.ex never registered through allow_tag_with_uri_attributes/3, and its only guard is a prefix match on lowercase "javascript:", so mixed-case variants, data: URIs, protocol-relative URLs and same-origin paths all survive. This is not unconditional cross-site scripting. A javascript: URL does not execute through <object data> in current browsers, data: documents load in an opaque origin, and host-origin script execution additionally requires the application to serve attacker-controlled content from a same-origin path. This issue affects html_sanitize_ex: from 0.3.1 before 1.4.5 and from 1.5.0-rc.0 before 1.5.3.
A vulnerability allowing the inclusion of functionality from an untrusted control sphere has been identified in the HTML5 scrubber of rrrene html_sanitize_ex, versions 0.3.1 prior to 1.5.3. This vulnerability allows remote attackers to load arbitrary documents into a trusted page using the data attribute of an <object> element within sanitized HTML. The <object> element is the only URI-bearing element in the HTML5 scrubber that is not properly sanitized, as it is not registered to allow URI attributes and only filters out lowercase 'javascript:' URLs. As a result, mixed-case 'javascript:' URLs, 'data:' URIs, protocol-relative URLs, and same-origin paths can bypass the sanitation and remain intact. While this vulnerability does not constitute unconditional cross-site scripting—since 'javascript:' URLs do not execute via <object data> in current browsers, 'data:' documents are loaded in an opaque origin, and executing scripts from the host origin requires serving attacker-controlled content from a same-origin path— it still poses a significant risk by allowing untrusted content to be embedded in a trusted context.
Users can update to rrrene html_sanitize_ex version 1.5.3 or later, where this vulnerability has been fixed. Alternatively, a custom scrubber can be defined that omits the <object> element, or one can use the 'basic_html', 'markdown_html', or 'strip_tags' functions, which do not allow <object> elements. For applications that host user uploads, serving these files from a separate origin can also mitigate the risk.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Aug 6, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://cna.erlef.org/cves/CVE-2026-66843.html | EEF | PatchThird Party Advisory |
| https://github.com/rrrene/html_sanitize_ex/commit/bec27fec4de99e40c68c4285a610e09e791a3eaf | EEF | Patch |
| https://github.com/rrrene/html_sanitize_ex/commit/ce038aa1af5a960d50f8eb5d368cc57bb2b9a9f0 | EEF | |
| https://github.com/rrrene/html_sanitize_ex/security/advisories/GHSA-xmm9-jc22-rcgj | EEF | Broken Link |
| https://osv.dev/vulnerability/EEF-CVE-2026-66843 | EEF | PatchThird Party Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-829 | Inclusion of Functionality from Untrusted Control Sphere | EEF |
Affected Products
| Product | Versions |
|---|---|
| rrrene htmlsanitizeex | >= 0.3.1, < 1.5.3 |
CPE
Remediation
| |
Change History
4 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Aug 19, 2026 | CVE Modified | EEF |
| Aug 11, 2026 | Initial Analysis | [email protected] |
| Aug 6, 2026 | CVE Modified | CISA-ADP |
| Aug 6, 2026 | New CVE Received | EEF |