What’s Vulnerable › Vulnerabilities

CVE-2026-115754: serialize-javascript 7.0.1 before 7.1.3 XSS via unescaped </script in function body

Description

serialize-javascript from 7.0.1 before 7.1.3 contains a cross-site scripting vulnerability that allows attackers to break out of HTML script elements by ending serialized function source text with an unescaped </script. Attackers controlling a function's source via a spoofed toString() can combine surrounding output delimiters and later values to inject live markup such as img onerror handlers.

Affected products

How to fix

Upgrade to a fixed version: Npm Serialize-Javascript 7.1.3; yahoo serialize-javascript 7.1.3. Check the vendor advisory for mitigations.

References

Get alerted when CVE-2026-115754 or the next vulnerability affects your stack