CVE-2026-116581: Seroval: fromJSON deserializer trusts node-supplied array length and sequence doneAt (unauthenticated event-loop DoS)
seroval, the npm serializer, trusts two node fields in `fromJSON` and `fromCrossJSON`: an array node's element list and a sequence node's done index. A small unauthenticated payload can block the event loop or create an iterator that never finishes. All versions up to 1.6.7 are affected. Fixed in 1.6.8, with no workaround.
Published Oct 28, 2026 · Analysis Nov 1, 2026
What an attacker can do
The decoder uses node fields from the payload without checking them. For array nodes, the element list was not verified to be an array, so a tiny payload could set the length the decoder loops over and block the thread while it runs. This half is also tracked in GHSA-wp97-x4hv-qvhp.
For sequence nodes, the done index was not validated. A crafted value produces an iterator that never ends, so any code that reads the iterator to the end runs forever.
Any service that passes untrusted input to fromJSON or fromCrossJSON can be taken offline by an unauthenticated request. A single Node.js process serves all requests on one event loop, so one blocked request stalls everyone. The impact is availability only: no data is read or changed.
Who is affected
seroval 1.6.7 and earlier. You are exposed if a network-facing service decodes client-supplied data with fromJSON or fromCrossJSON. This includes frameworks that decode request bodies with these functions. Seroval is often a transitive dependency, so check the full tree:
npm ls serovalseroval
- Ecosystem
- npm
- Affected
- <= 1.6.7
- Fixed in
- 1.6.8
- Check
npm ls seroval
How to fix it
Upgrade to [email protected].
npm install [email protected]The patch requires element lists to be arrays and requires a sequence node's throw and done indices to be integers from -1 up to the last element index. Invalid input now throws SerovalMalformedNodeError. The advisory lists no workaround, so upgrade. For transitive copies, update the parent package or force the version with your package manager's overrides.
How to tell if you were hit
Look for requests that make a worker pin the CPU or stop answering, with no matching spike in traffic volume. Event-loop lag alerts and watchdog restarts on services that decode serialized bodies are the best signal. After the upgrade, malformed payloads show up as SerovalMalformedNodeError in your error logs, which tells you someone is probing. Check lockfiles for seroval at 1.6.7 or lower.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
fromJSON and fromCrossJSON used two node fields without checking them.
- An array node's element list was not checked to be an array. A small payload could set the length the decoder looped over. This part is also tracked in GHSA-wp97-x4hv-qvhp.
- A sequence node's done index was not checked. A crafted value produced an iterator that never finished.
Impact
A service that passes untrusted input to fromJSON or fromCrossJSON can be made unavailable by an unauthenticated request.
- The array case blocks the thread while the decoder runs.
- The sequence case makes any code that reads the resulting iterator to the end run forever.
Patches
Fixed in [email protected].
- Element lists must be arrays.
- A sequence node's throw and done indices must be integers from -1 up to the last element index.
Invalid input throws SerovalMalformedNodeError.
Workarounds
None. Upgrade to 1.6.8.
Credited to realies.
Questions
- Does CVE-2026-116581 need authentication?
No. The vector is network, no privileges, no user interaction. Any client that can reach a code path calling
fromJSONorfromCrossJSONwith its input can trigger it.- Is there a workaround besides upgrading?
The advisory says none. Upgrade to seroval 1.6.8, which validates the element list and the sequence throw and done indices.
- What is the difference from GHSA-wp97-x4hv-qvhp?
The array-length part is shared with that advisory. This one adds the sequence node done index, which can produce an iterator that never finishes. Both are fixed in 1.6.8.
- Is it exploited in the wild?
No source reports exploitation, and the entry is not in CISA's KEV catalog.
References
Read for this analysis:
- https://nvd.nist.gov/vuln/detail/CVE-2026-116581
- https://github.com/lxsmnsyc/seroval/commit/cdcee3e3bc384ee844360844f8ea98fd2b275d69
- https://github.com/lxsmnsyc/seroval/commit/e176f9267e59ddd6c9de89cc9fe85c5b37a5b728
- https://github.com/lxsmnsyc/seroval/releases/tag/[email protected]
- https://github.com/advisories/GHSA-97r2-qh9m-474h
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology
More npm vulnerabilities
All npm entriesCVE-2026-116580
Seroval: Deserialization invokes attacker-chosen callables: AsyncIteratorFactoryInstance calls source.on(listener) without type check
high7.3Oct 28, 2026CVE-2026-116582
Seroval: Script injection through RegExp sources in serialized output
medium4.7Oct 28, 2026CVE-2026-116583
Seroval: Code injection through a typed array's own constructor property
medium5.3Oct 28, 2026CVE-2026-116584
Seroval `fromJSON`/`fromCrossJSON` denial of service via unvalidated array node length
high7.5Oct 28, 2026CVE-2026-104845
Seroval: Memory exhaustion via unchecked TypedArray length in JSON deserialization
high7.5Oct 5, 2026CVE-2026-104846
Seroval: `fromJSON()` Promise thenable assimilation invokes plugin-produced callables (bypass of GHSA-mv8w-475r-vwqw)
critical9.8Oct 5, 2026
