Track vulnerabilities like this one.
Sign up free to get alerted when software you use is affected.
2.3
CVE-2026-92106: lazy_html can let attackers run malicious scripts
CVE-2026-92106 · published 24 days ago
Summary
The lazy_html library used to convert HTML can be fooled by specially crafted SVG or MathML content. The hidden code can then execute in a visitor’s browser, potentially exposing data or hijacking the session. Update to version 0.1.13 or later, or replace the library with a safer alternative.
What to do
- Update dashbit lazy_html to version 0.1.13.
- Update lazy_html to version 0.1.13.
Affected software
| Ecosystem | Vendor | Product | Affected versions |
|---|---|---|---|
| – | dashbitco | lazy_html |
< 0.1.13 < f32c7fd6223225b68bc8691c78b6d4a77972f1d5 |
| Hex | dashbit | lazy_html |
>= 0.1.0, < 0.1.13 Fix: upgrade to 0.1.13
|
| Hex | – | lazy_html |
>= 0.1.0, < 0.1.13 Fix: upgrade to 0.1.13
|
Original advisory text
lazy_html serializes SVG and MathML style and script text unescaped, allowing mutation XSS
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') vulnerability in dashbitco lazy_html allows mutation XSS via a parse and serialize round-trip of attacker-supplied HTML.
LazyHTML.to_html/2 and LazyHTML.Tree.to_html/2 decide whether to escape an element's text from its tag name alone. A style or script element inside SVG or MathML foreign content is parsed with character references decoded, but is serialized as an HTML raw-text element, so its text is emitted unescaped. Encoded markup such as </style><img src=x onerror=...> inside <svg><style> therefore closes the element on re-parse and becomes live markup. Applications that parse untrusted HTML with lazy_html, filter the document or tree, and serialize it for display are affected, since the payload is a plain text node that no element or attribute filter sees.
This issue affects lazy_html: from 0.1.0 before 0.1.13.
LazyHTML.to_html/2 and LazyHTML.Tree.to_html/2 decide whether to escape an element's text from its tag name alone. A style or script element inside SVG or MathML foreign content is parsed with character references decoded, but is serialized as an HTML raw-text element, so its text is emitted unescaped. Encoded markup such as </style><img src=x onerror=...> inside <svg><style> therefore closes the element on re-parse and becomes live markup. Applications that parse untrusted HTML with lazy_html, filter the document or tree, and serialize it for display are affected, since the payload is a plain text node that no element or attribute filter sees.
This issue affects lazy_html: from 0.1.0 before 0.1.13.
References
- https://osv.dev/vulnerability/EEF-CVE-2026-92106
- https://hex.pm/packages/lazy_html Product
- https://cna.erlef.org/cves/CVE-2026-92106.html
- https://github.com URL
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/92xxx/CVE-2026-92106... Vendor Advisory
- https://nvd.nist.gov/vuln/detail/CVE-2026-92106 Vendor Advisory
- https://repo.hex.pm URL
- https://github.com/dashbitco/lazy_html/commit/1dee15746c024916b3110af8b168c2f3b3...
- https://github.com/dashbitco/lazy_html/commit/f32c7fd6223225b68bc8691c78b6d4a779...
- https://github.com/dashbitco/lazy_html/security/advisories/GHSA-8rqp-v692-v82q
- https://github.com/dashbitco/lazy_html Product
Internet-facing
60 days
Internal
At next upgrade
- Not known to be exploited
- Needs hands-on effort to exploit
- Gives an attacker partial control
Severity
2.3
Low
Type
CWE-79Cross-site Scripting (XSS)
Timeline
Published25 Sep 2026
Updated19 Oct 2026
First seen25 Sep 2026
Sources
CVE-2026-92106 · NVD
CVE-2026-92106 · MITRE
EEF-CVE-2026-92106 · OSV
GHSA-8rqp-v692-v82q · GHSA
CVE-2026-92106 · OSV
Track software like this
Free during beta