CVE-2026-116582: Seroval · Script injection through RegExp sources in serialized output
Affects serovalSource GCVE Database
Not known to be exploited · CVSS 4.7 Medium : upgrade to 1.6.10 when convenient.
Data as of 28 Oct 2026, 22:12 UTC
- Patch
- Available – fixed in 1.6.10, 1.0.0
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:NExploitation evidence
Disclosed: evidence found.
CVE published 26 Oct 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Upgrade seroval to 1.6.10; seroval to 1.0.0.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| npmseroval | Affected
| Fixed in
|
| npmseroval | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
Description
### Summary seroval writes a `RegExp` as a regular expression literal. In affected versions, the `<` character in a `RegExp` source is written without escaping. A source built from untrusted input can then end the HTML `<script>` element that the serialized output is placed in, and run script in the page. ### Details seroval escapes `<` in strings, so string values cannot end a `<script>` element. `RegExp` sources did not get the same escaping: - Versions before 1.0.0 wrote the source as is. - Version 1.5.5 stopped escaping `<` in `RegExp` sources, so that named groups and lookbehinds keep working. This removed the escaping for every `<` in a source. These functions are affected: - `serialize`, `serializeAsync` - `crossSerialize`, `crossSerializeAsync`, `crossSerializeStream` - the `Serializer` class - `compileJSON` `toJSON`, `fromJSON`, `toCrossJSON` and `fromCrossJSON` are not affected, because they never produce JavaScript. ### Impact An application is affected when all of these are true: 1. It builds a `RegExp` from untrusted input that is used as regular expression syntax. Input passed through an escaping helper (such as an `escapeRegExp` function) is not enough to exploit this. 2. It serializes that `RegExp` with one of the functions above. 3. It places the output inside an HTML `<script>` element, as server rendering usually does. In that case an attacker can run script in the page of any user who receives that output. ### Patches Fixed in 1.6.10. A `RegExp` whose source contains `<` is now written with the `RegExp` constructor and an escaped string source. Named groups and lookbehinds keep working. ### Workarounds If you cannot upgrade: - Do not serialize a `RegExp` built from untrusted pattern syntax. Send its source and flags as strings, and build the `RegExp` on the client. - Or reject patterns that contain `<` before they reach the serializer.
References
- github.com/lxsmnsyc/seroval/security/advisories/GHSA-9wx9-5pv9-3349 (opens in a new tab)
- nvd.nist.gov/vuln/detail/CVE-2026-116582 (opens in a new tab)
- github.com/lxsmnsyc/seroval/commit/f94ee0b63936dae954ff50d5b5e8ea7cb9b284e6 (opens in a new tab)
- github.com/lxsmnsyc/seroval (opens in a new tab)
- github.com/lxsmnsyc/seroval/releases/tag/seroval@1.6.10 (opens in a new tab)