in serialized function bodies","description":"Serialize JavaScript serializes JavaScript values to a superset of JSON that includes regular expressions and functions.","datePublished":"2026-09-29T16:00:33.534000+00:00","dateModified":"2026-09-29T16:53:35.013000+00:00","inLanguage":"en","author":{"@type":"Organization","@id":"https://vexday.io/#org","name":"Vexday","url":"https://vexday.io","logo":{"@type":"ImageObject","url":"https://vexday.io/icon.png"}},"publisher":{"@type":"Organization","@id":"https://vexday.io/#org","name":"Vexday","url":"https://vexday.io","logo":{"@type":"ImageObject","url":"https://vexday.io/icon.png"}},"mainEntityOfPage":"https://vexday.io/en/cve/CVE-2026-97711","about":{"@type":"SoftwareApplication","name":"yahoo serialize-javascript"},"keywords":"CVE-2026-97711, yahoo serialize-javascript, CWE-79"}
CVE-2026-97711lowCWE-79

CVE-2026-97711: low-severity vulnerability in yahoo serialize-javascript

Serialize JavaScript: Cross-site scripting (XSS) via unescaped </script> in serialized function bodies

Published

8Vexday Risk Score

No sign of exploitation. No public exploitation artifact known so far.

ssvc Trackcvss 2.3epss 0.3%
exploitation probability
0.3%top 79% of all CVEs
observed exploitation
nono source reports it
Serialize JavaScript serializes JavaScript values to a superset of JSON that includes regular expressions and functions. From 7.1.1 until 7.1.2, function values serialized by serialize-javascript are not fully protected against script-closing tags in attacker-influenced function source because SCRIPT_CLOSE_REGEXP can consume a second closing tag inside one match. When the serialized function is embedded in a script element, the surviving closing tag terminates the element early and causes the remaining output to be parsed as HTML, enabling cross-site scripting in the page origin. Only function values are affected; ordinary data values and options.isJSON output are unaffected. This issue is fixed in version 7.1.2.
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