CVE-2019-25061
HIGH 7.5CVSS 3.1Insecure PRNG use in random_password_generator
The random_password_generator (aka RandomPasswordGenerator) gem through 1.0.0 for Ruby uses Kernel#rand to generate passwords, which, due to its cyclic nature, can facilitate password prediction.
- Published
- 18 May 2022
- Last modified
- 17 Jun 2026
- Assigned by
- cve@mitre.org
- NVD status
- Modified
- Weakness
- CWE-330CWE-335
- Also known as
- GHSA-ggfx-h9xj-5v9c
- Sources
- NVDJSONOSV GHSA-ggfx-h9xj-5v9cJSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | HIGH 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
| OSV | GitHub | CVSS 3.1 | HIGH 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | MEDIUM 5.0 | AV:N/AC:L/Au:N/C:P/I:N/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | random_password_generator_project | random_password_generatorcpe:2.3:a:random_password_generator_project:random_password_generator:*:*:*:*:*:ruby:*:* |
<= 1.0.0 | |
| OSV | RubyGems | random_password_generator | <= 1.0.0 |
References
- https://github.com/bvsatyaram/random_password_generator/blob/2855e8d7d8803dbb580ddd6cf13846394eb4530e/lib/random_password_generator.rb#L23 · Third Party Advisory, WEB
- https://github.com/bvsatyaram/random_password_generator/pull/1 · Issue Tracking, Third Party Advisory, WEB
- https://ruby-doc.org/core-3.1.2/Random.html · Third Party Advisory, WEB
- https://stackoverflow.com/questions/42170239/security-of-rand-in-ruby-compared-to-other-methods/42170560 · Exploit, Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2019-25061 · ADVISORY
- https://github.com/bvsatyaram/random_password_generator · PACKAGE
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/random_password_generator/CVE-2019-25061.yml · WEB
History
- 25 Nov 2026 20:34 UTC · NVD: first stored (published 18 May 2022)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 19 May 2022)