Skip to main content

html_sanitize_ex EUVDEUVD-2026-54080

| CVE-2026-66843 LOW
Inclusion of Functionality from Untrusted Control Sphere (CWE-829)
2026-08-06 EEF GHSA-6g7x-33rf-28v3
2.3
CVSS 4.0 · Vendor: EEF
View

Attack ChainAIDerived

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

  1. Access
    Attacker crafts object tag with bypass URI
  2. Delivery
    Submits to application accepting user HTML
  3. Exploit
    HTML5 scrubber passes data attribute (case/scheme bypass)
  4. Execution
    Victim loads page in browser
  5. Persist
    Browser fetches and embeds attacker-specified document
  6. Impact
    UI deception or same-origin content execution

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A08:2025 - Software or Data Integrity Failures
ASVS 5.0
V15 - Secure Coding and Architecture Trusted source inclusion only
Exploitation Conditions

Exploitation requires: (1) the application uses html_sanitize_ex 0.3.1 through before 1.5.3 with the HTML5 scrubber specifically; (2) untrusted user input reaches the scrubber and the sanitized output is rendered in a browser without further attribute stripping; and (3) the attacker can submit content containing an <object> element with a crafted data attribute using a mixed-case scheme (JavaScript:), a data: URI, a protocol-relative URL (//attacker.example/...), or a same-origin relative path (/user-uploads/...). The highest-impact variant - host-origin script execution - additionally requires the application to serve attacker-controlled file content from a same-origin path, which is a separate application-level precondition. Limiting factors: javascript: URLs do not execute via <object data> in current browsers; data: URI content loads in an opaque origin, isolating it from the embedding page; external-URL embedding is cross-origin and restricted by browser isolation; the CVSS AT:P metric confirms these additional requirements are present. Authentication level to submit content depends on application-level controls, not the library itself.

Impact

The CVSS 4.0 score of 2.3 (Low) and vector AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N is an accurate characterization of real-world risk and is consistent with the CVE description's explicit caveats. AT:P (attack requirements: present) correctly reflects that meaningful exploitation depends on conditions beyond the sanitizer bypass itself: the most impactful scenario - host-origin script execution - additionally requires the application to serve attacker-controlled files from a same-origin path (e.g., a file upload feature). The description explicitly states that javascript: URLs do not execute through <object data> in current browsers, data: URI documents load in an opaque origin with no access to the embedding page, and same-origin code execution requires a secondary vulnerability (application-level user-controlled file hosting). The downstream impact is therefore primarily UI deception via embedded cross-origin documents (SC:L/SI:L) rather than direct XSS. No KEV listing and no confirmed POC exist, and EPSS data was not provided in the input. This is a genuine sanitizer logic flaw worth patching for defense-in-depth, but the actual exploitation bar is substantially higher than a headline CWE-829 classification might imply.

Exploit ScenarioDerived

An attacker submits a comment or post containing <object data="//attacker.example/phishing.html"></object> or <object data="/user-uploads/attacker.html"></object> to an application using the vulnerable HTML5 scrubber. The sanitizer passes the <object> tag with the malicious data attribute intact because the // prefix and relative / prefix were not blocked by the original guard. When a victim views the page, the browser embeds the attacker-specified document in the trusted page, enabling phishing UI overlays or - if the application also hosts attacker-controlled files at a same-origin path - potential script execution within the page origin.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.5% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Aug 06, 2026

html_sanitize_ex's HTML5 scrubber (versions 0.3.1 through before 1.5.3) passes attacker-controlled URIs through the data attribute of <object> elements after a trivially bypassed case-sensitive prefix check, allowing remote attackers to embed arbitrary external or same-origin documents into sanitized pages viewed by victims. The <object> tag was never registered through the library's allow_tag_with_uri_attributes/3 URI-validation mechanism, and its sole guard - a literal lowercase javascript: prefix match - is defeated by mixed-case variants, data: URIs, protocol-relative URLs, and same-origin relative paths. No public exploit has been identified at time of analysis, and no active exploitation (CISA KEV) has been confirmed; the CVSS 4.0 score of 2.3 correctly reflects constrained real-world impact due to browser-enforced origin isolation on embedded <object> content.

RemediationAI

Upgrade html_sanitize_ex to version 1.5.3 or later; this is the vendor-confirmed fix version per the GitHub advisory GHSA-xmm9-jc22-rcgj and is delivered by the patch commit at https://github.com/rrrene/html_sanitize_ex/commit/bec27fec4de99e40c68c4285a610e09e791a3eaf. In mix.exs, update the dependency to {:html_sanitize_ex, "~> 1.5.3"} and run mix deps.update html_sanitize_ex. If an immediate upgrade is not feasible, a targeted compensating control is to post-process sanitized output to strip all remaining <object> elements (e.g., via a secondary regex or DOM traversal) before rendering - this eliminates the attack surface entirely but also removes any legitimate <object> usage from user content, which may be an acceptable trade-off in most applications. A softer control - allowlisting only https: URIs in the data attribute via application-layer validation after sanitization - is narrower but more error-prone to implement correctly given the bypass class being exploited.

Affected VersionsENISA

html_sanitize_ex 8976d64ea0b77d26093a94a43ec48a3978e8d028 <bec27fec4de99e40c68c4285a610e09e791a3eaf
html_sanitize_ex 0.3.1 <1.5.3

Affected Packages

euvd html_sanitize_ex fix: 1.5.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

The vulnerability originates in lib/html_sanitize_ex/scrubber/html5.ex within the html_sanitize_ex Elixir library (CPE: cpe:2.3:a:rrrene:html_sanitize_ex). The library's HTML5 scrubber allowlists tags and attributes; URI-carrying attributes on elements such as <a>, <img>, and <source> are validated through allow_tag_with_uri_attributes/3, which enforces comprehensive URI scheme allowlisting. The <object> element was never registered through this mechanism. Its data attribute instead relied on a single Elixir pattern match: {"data", "javascript:" <> _} -> nil, which is both case-sensitive and scheme-incomplete. CWE-829 (Inclusion of Functionality from Untrusted Control Sphere) is the root cause class: the scrubber allows the page to incorporate content from an untrusted URI because the guard does not normalize case, does not enumerate all dangerous schemes (e.g., data:), and does not block protocol-relative (//) or relative (/) paths resolvable to the same origin. The patch (commit bec27fec4de99e40c68c4285a610e09e791a3eaf) replaces the literal match with a case-insensitive regex check that rejects values starting with / and any value containing the substrings javascript or data, closing all documented bypass variants confirmed by six new regression tests.

Know when Html Sanitize Ex 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 (EEF) PRIMARY 2.3 LOW
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
vuln.today AI 4.7 MEDIUM

AC:H reflects the additional same-origin file-serving precondition for meaningful impact; S:C captures embedded foreign document loading into trusted page scope; no availability impact applies.

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

Primary rating from Vendor (EEF).

CVSS VectorVendor: EEF

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
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

DescriptionCVE.org

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.5.3.

Threat Intelligence Overview

EPSS Score
0.5%
Top 60% exploitable
Prevalence
Low
Elixir-ecosystem library, niche language with limited enterprise footprint
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GitHub VulDB

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 LOW
CISA KEV No
Public POC No
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.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
Defer
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Low
Technical Impact
Partial

Priority Score

12
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +12
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