Serialize JavaScript has CPU Exhaustion Denial of Service via crafted array-like objects
Impact
What kind of vulnerability is it?
It is a Denial of Service (DoS) vulnerability caused by CPU exhaustion. When serializing a specially crafted "array-like" object (an object that inherits from Array.prototype but has a very large length property), the process enters an intensive loop that consumes 100% CPU and hangs indefinitely.
Who is impacted?
Applications that use serialize-javascript to serialize untrusted or user-controlled objects are at risk. While direct exploitation is difficult, it becomes a high-priority threat if the application is also vulnerable to Prototype Pollution or handles untrusted data via YAML Deserialization, as these could be used to inject the malicious object.
Patches
Has the problem been patched?
Yes, the issue has been patched by replacing instanceof Array checks with Array.isArray() and using Object.keys() for sparse array detection.
What versions should users upgrade to?
Users should upgrade to v7.0.5 or later.
Workarounds
Is there a way for users to fix or remediate the vulnerability without upgrading?
There is no direct code-level workaround within the library itself. However, users can mitigate the risk by:
- Validating and sanitizing all input before passing it to the
serialize()function. - Ensuring the environment is protected against Prototype Pollution.
- Upgrading to
v7.0.5as soon as possible.
Acknowledgements
Serialize JavaScript thanks Tomer Aberbach (@TomerAberbach) for discovering and privately disclosing this issue.
Affected Packages
| Ecosystem | Package | Vulnerable Versions | Patched Version |
|---|---|---|---|
| npm |
serialize-javascript
|
>= 5.0.0, < 7.0.5 |
7.0.5
|
Bump the npm-security-updates group across 2 directories with 5 updates
Open 5 days agoBump the npm-security group across 1 directory with 13 updates
Closed 6 days agoBump serialize-javascript and @iobroker/testing
Open 12 days agochore(deps): bump serialize-javascript and @iobroker/testing
Open 16 days agochore(deps): bump serialize-javascript and mocha in /shopping-list
Closed 17 days agoci(deps): bump serialize-javascript and mocha
Closed 19 days agoBump the npm_and_yarn group across 3 directories with 19 updates
Open about 1 month agochore(deps): bump serialize-javascript from 6.0.2 to 7.1.1 in the npm_and_yarn group across 1 directory
Closed about 1 month agoBump the npm_and_yarn group across 3 directories with 18 updates
Open about 1 month agoBump serialize-javascript and mocha
Open about 1 month agochore(deps): bump serialize-javascript and mocha
Closed about 1 month agobuild(deps): bump serialize-javascript and mocha
Closed about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agochore(deps): bump serialize-javascript and mocha
Closed about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agoBump serialize-javascript and @iobroker/testing
Open about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agoBump serialize-javascript and mocha
Open about 1 month agoBump serialize-javascript and mocha
Open about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agoBump the npm_and_yarn group across 1 directory with 8 updates
Closed about 1 month agoBump serialize-javascript and @iobroker/testing
Closed about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agochore(deps): bump serialize-javascript and mocha
Closed about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agodeps: bump the npm_and_yarn group across 1 directory with 2 updates
Closed about 1 month agoBump serialize-javascript and @iobroker/testing
Closed about 1 month agoBump serialize-javascript and @iobroker/testing
Open about 1 month agoBump the npm_and_yarn group across 1 directory with 11 updates
Open about 1 month agoBump the npm_and_yarn group across 1 directory with 7 updates
Closed about 1 month agoBump serialize-javascript and mocha
Closed about 1 month agochore(deps): bump serialize-javascript and @iobroker/testing
Open about 1 month agoBump serialize-javascript from 6.0.2 to 7.1.1 in the npm_and_yarn group across 1 directory
Open about 1 month agoBump serialize-javascript and @iobroker/testing
Open about 1 month agoBump the npm_and_yarn group across 1 directory with 4 updates
Closed about 1 month agochore(deps): bump serialize-javascript and @angular-devkit/build-angular in /frontend
Open about 1 month agoBump the npm_and_yarn group across 1 directory with 7 updates
Closed about 1 month agoBump the npm_and_yarn group across 1 directory with 6 updates
Closed about 1 month agoBump serialize-javascript from 6.0.2 to 7.1.1 in the npm_and_yarn group across 1 directory
Closed about 1 month agochore(deps): bump the npm_and_yarn group across 1 directory with 9 updates
Open about 1 month agochore(deps): bump serialize-javascript and mocha in /packages/sdks/@flagmind/edge
Open about 1 month agoBump serialize-javascript and mocha
Open about 1 month agoBump the npm_and_yarn group across 1 directory with 6 updates
Closed about 1 month agochore(deps): bump serialize-javascript and mocha
Open about 1 month agobuild(deps): bump serialize-javascript and mocha
Closed about 1 month agobuild(deps): Bump serialize-javascript and mocha in /src/LoggerUsage.VSCode
Open about 2 months agochore(deps): bump serialize-javascript, @rollup/plugin-terser and mocha
Closed about 2 months agoBump serialize-javascript and mocha
Closed about 2 months agoBump serialize-javascript and mocha in /packages/vscode-extension
Closed about 2 months agoActions
Advisory Details
| Published: | March 27, 2026 7 months ago |
| Updated: | October 16, 2026 2 days ago |
| CVSS Score: | 5.9 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H |
| EPSS: | 0.58% 47th percentile |
| Source: | Github |
| Classification: | GENERAL |
| UUID: | GSA_kwCzR0hTQS1xajh3LWdmajUtOGM2ds4ABUYo |
PR Statistics
References
- https://github.com/yahoo/serialize-javascript/security/advisories/GHSA-qj8w-gfj5-8c6v
- https://github.com/yahoo/serialize-javascript/commit/f147e90269b58bb6e539cfdf3d0e20d6ad14204b
- https://github.com/yahoo/serialize-javascript/releases/tag/v7.0.5
- https://nvd.nist.gov/vuln/detail/CVE-2026-34043
- https://github.com/yahoo/serialize-javascript/releases/tag/v5.0.0
- https://github.com/advisories/GHSA-qj8w-gfj5-8c6v