crypto-js uses insecure random numbers
The crypto-js package 3.2.0 for Node.js generates random numbers by concatenating the string "0." with an integer, which makes the output more predictable than necessary.
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| npm package | crypto-js | >= 3.2.0, < 3.2.1 | 3.2.1 |
References
- https://nvd.nist.gov/vuln/detail/CVE-2020-36732
- https://github.com/brix/crypto-js/issues/254
- https://github.com/brix/crypto-js/issues/256
- https://github.com/brix/crypto-js/pull/257/commits/e4ac157d8b75b962d6538fc0b996e5d4d5a9466b
- https://github.com/brix/crypto-js/commit/b405ff597fb3ac76a7bdfbc72dca10ba1079b1d5
- https://github.com/brix/crypto-js/commit/e4ac157d8b75b962d6538fc0b996e5d4d5a9466b
- https://github.com/brix/crypto-js
- https://github.com/brix/crypto-js/compare/3.2.0...3.2.1
- https://security.netapp.com/advisory/ntap-20230706-0003
- https://security.snyk.io/vuln/SNYK-JS-CRYPTOJS-548472
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N- Weakness (CWE)
CWE-330, CWE-331- Platform
- npm
- Package
crypto-js- Disclosed
- 12.06.2023
- Updated
- 11.10.2026 10:22
Sources and licenses
OSV / GitHub Advisory Database - GHSA-3w3w-pxmm-2w2j - CC BY 4.0
Vulnerability history: crypto-js
All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.
- Total entries
- 3
- First → latest
- 06.2023 08.2026
- Without a fix
- 0
- Exploited in attacks
- 0
Severity breakdown
- Critical 2
- Medium 1
Disclosures per year
- 2023: 2
- 2024: 0
- 2025: 0
- 2026: 1
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.