Description
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 breakdown
CVSS 3.1
Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None
Affected products
- nodejs / node4.0 – 4.*
- nodejs / node5.0 – 5.*
- nodejs / node6.0 – 6.*
- nodejs / node7.0 – 7.*
- nodejs / node8.0 – 8.*
- nodejs / node9.0 – 9.*
- nodejs / node10.0 – 10.*
- nodejs / node11.0 – 11.*
- nodejs / node12.0 – 12.*
- nodejs / node13.0 – 13.*
- nodejs / node15.0 – 15.*
- nodejs / node17.0 – 17.*
- nodejs / node18.0 – 18.9.1