Cross-site scripting in serialize-javascript via unescaped closing script prefix
Key facts
- Attack vector
- Network
- Privileges required
- Low
- User interaction
- Passive
- Attack complexity
- High
- Attack requirements
- Present
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- Low · Low · None
- Fix status
- Fixed
Attack profile from CVSS 4.0 · CNA. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-79.
Summary
Serialize JavaScript (serialize-javascript) versions from 0 before 7.1.3 are affected. The function-source escaping logic fails to neutralize a bare closing script prefix when attacker-influenced function source ends exactly at that prefix, which is a cross-site scripting weakness (CWE-79). An attacker who controls a serialized function's source text, such as through a spoofed toString(), can have a delimiter from surrounding serialized output end an HTML script element and inject markup that becomes a live element in the page. The CVSS 4.0 vector rates this as low severity with passive user interaction required.
Written with Claude Haiku 5.5 from the sources below · 2026-11-03
Description from the CNA
Serialize JavaScript serializes JavaScript values to a superset of JSON that includes regular expressions and functions. Prior to 7.1.3, the function-source escaping logic does not neutralize a bare closing-script prefix when attacker-influenced function source text ends exactly at that prefix. Because each function body is escaped independently, a delimiter supplied by surrounding serialized output can terminate an HTML script element, and a later serialized value supplies injected markup that becomes a live element in the page. Exploitation requires control of a serialized function's source text, such as through a spoofed toString(). This issue is fixed in version 7.1.3.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| yahoo | serialize-javascript | before 7.1.3 | 7.1.3 | Patch available | CNA |
| — | serialize-javascript (npm) | before 7.1.3 | 7.1.3 | Patch available | GHSA-m5mm-p8h7-m29v |
- serialize-javascript Vendoryahoo Affected before 7.1.3 Fixed in 7.1.3 Patch available CNA
- serialize-javascript (npm) Vendor— Affected before 7.1.3 Fixed in 7.1.3 Patch available GHSA-m5mm-p8h7-m29v
Remediation
Update serialize-javascript to version 7.1.3, which fixes the issue. Red Hat fixes Red Hat Hardened Images in advisory RHSA-2026:93601, released 2026-11-02.
Written with Claude Haiku 5.5 from the sources below · 2026-11-03
- Fix · CNA serialize-javascript (yahoo) Fixed in 7.1.3
- Fix · GHSA-m5mm-p8h7-m29v serialize-javascript (npm) Fixed in 7.1.3 Advisory →
Red Hat 1 advisory
- RHSA-2026:93601 Released 2026-11-02 · Red Hat rating ImportantRed Hat Hardened Images RPMs Security Update
- Red Hat Hardened Images grafana12.4-12.4.13-0.6.hum1@aarch64, grafana12.4-12.4.13-0.6.hum1@src, grafana12.4-12.4.13-0.6.hum1@x86_64
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Hardened Images | Fixed | RHSA-2026:93601 |
Not affected: 1 product
- Red Hat Hardened Images
Timeline
- 2026-10-23 Threatist record created from CVE-2026-115897
- 2026-10-23 Alias added: GHSA-m5mm-p8h7-m29v
- 2026-10-23 Fix available: npm/[email protected] · GHSA-m5mm-p8h7-m29v
- 2026-10-23 CVSS score added · GHSA-m5mm-p8h7-m29v
- 2026-10-23 Weakness changed · GHSA-m5mm-p8h7-m29v
- 2026-10-23 5 new references · GHSA-m5mm-p8h7-m29v
- 2026-10-24 Affected versions changed · Red Hat
- 2026-10-24 CVSS score added · Red Hat
- 2026-10-26 CISA SSVC decision points changed
- 2026-11-03 Fix available: RHSA-2026:93601 · Red Hat
- 2026-11-03 Fix available: Red Hat Hardened Images · Red Hat
References
Other 5
- https://github.com/yahoo/serialize-javascript/security/advisories/GHSA-m5mm-p8h7-m29v
- https://github.com/yahoo/serialize-javascript/pull/235
- https://github.com/yahoo/serialize-javascript/commit/2864b3c6260a3bfd52d2db3e70d1a079de108a61
- https://github.com/yahoo/serialize-javascript/releases/tag/v7.1.3
- https://github.com/yahoo/serialize-javascript
More yahoo vulnerabilities
- TI-2007-03044 Buffer overflow in the Yahoo! Webcam Upload ActiveX control in ywcupl.dll 2.0.1.4 for… CVSS 2.0HIGH 9.3
- TI-2026-62497 CMAK through 3.0.0.6 Cross-Site Request Forgery via Missing CSRF Filter CVSS 4.0HIGH 7.2
- TI-2007-04373 Buffer overflow in a certain ActiveX control in YVerInfo.dll before 2007.8.27.1 in the… CVSS 2.0HIGH 9.3
- TI-2026-41720 Elide 7.1.17 - Permission Bypass in Sort Expression Validation CVSS 4.0MEDIUM 5.3
- TI-2007-03904 Stack-based buffer overflow in the YDPCTL.YDPControl.1 (aka Yahoo! Installer Plugin for… CVSS 2.0HIGH 9.3
- TI-2007-03045 Buffer overflow in the Yahoo! Webcam Viewer ActiveX control in ywcvwr.dll 2.0.1.4 for… CVSS 2.0HIGH 9.3
Sources
- CVE-2026-115897 · CVE Program
- CVE-2026-115897 · NVD
- FIRST EPSS
- GHSA-m5mm-p8h7-m29v · GitHub Advisory Database · CC BY 4.0
- CVE-2026-115897 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences