CVE-2021-23451 json
Insecure Randomness
published 2022-07-25 4 y ago modified 2026-06-17 4 mo ago also GHSA-6x93-h9g3-9phr , EUVD-2022-6267
- cvss
- 6.5
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.9%
- EPSS 0.9% chance of exploitation in 30 days, percentile 60%
- public exploits
- 0
- none known
Summary
The package otp-generator before 3.0.0 are vulnerable to Insecure Randomness due to insecure generation of random one-time passwords, which may allow a brute-force attack.
Patch / fix
- npm otp-generator 3.0.0
- n/a otp-generator 3.0.0
Exploit prediction
0.91% chance of exploitation in the next 30 days, higher than 60% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 6.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N |
| NVD | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| GitHub | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| npm | otp-generator | <3.0.0 |
3.0.0 |
Affected products
- n/a otp-generator
Classification
- Weakness
-
- CWE-330 Use of Insufficiently Random Values
References
-
github.com
/Maheshkumar-Kakade/otp-generator/commit/b27de1ce439ae7f533cec26677e9698671275b70
web, patch, third-party-advisory
-
security.snyk.io
/vuln/SNYK-JS-OTPGENERATOR-1655480
web, issue-tracking, patch, third-party-advisory
-
github.com
/Maheshkumar-Kakade/otp-generator/issues/12
web, issue-tracking, third-party-advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-23451
advisory
-
github.com
/Maheshkumar-Kakade/otp-generator
package
Sources
- CVE List CVE-2021-23451
- GitHub Advisory GHSA-6x93-h9g3-9phr
- NVD CVE-2021-23451
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.