CVE-2022-35255: A weak randomness in WebCrypto keygen vulnerability exists in Node.js 18 due to a change with EntropySource() in SecretKeyGenTraits::DoKe…
CVE-2022-35255 affects 26 listed versions of Node.js in the Dawnsentry catalogue.
Affected products and versions
The versions in the Dawnsentry catalogue this CVE affects, judged from the vendor's own advisory where there is one, otherwise from the CVE record and NVD, as each version's own page says.
Node.js
26 of 250 listed versions are affected. Fixed in 18.9.1. The newest release, 26.14.0, is not affected.
18.9.0 18.8.0 18.7.0 18.6.0 18.5.0 18.4.0 18.3.0 18.2.0 18.1.0 18.0.5 18.0.0 17.9.1 17.9.0 17.8.0 17.7.2 17.7.1 17.7.0 17.6.0 17.5.0 17.4.0 17.3.1 17.3.0 17.2.0 17.1.0 17.0.1 17.0.0
What it is
A weak randomness in WebCrypto keygen vulnerability exists in Node.js 18 due to a change with EntropySource() in SecretKeyGenTraits::DoKeyGen() in src/crypto/crypto_keygen.cc. There are two problems with this: 1) It does not check the return value, it assumes EntropySource() always succeeds, but it can (and sometimes will) fail. 2) The random data returned byEntropySource() may not be cryptographically strong and therefore not suitable as keying material.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N (NVD)
Published by Hackerone on 5 December 2022. Last changed 17 June 2026.
Sources
Check one version you run: look CVE-2022-35255 up, or pick a product and version in the quick lookup.
Updated 2 December 2026.