CVE-2011-2705

Severity CVSS v4.0:
Pending analysis
Type:
CWE-20 Input Validation
Publication date:
05/08/2011
Last modified:
11/04/2025

Description

The SecureRandom.random_bytes function in lib/securerandom.rb in Ruby before 1.8.7-p352 and 1.9.x before 1.9.2-p290 relies on PID values for initialization, which makes it easier for context-dependent attackers to predict the result string by leveraging knowledge of random strings obtained in an earlier process with the same PID.

Vulnerable products and versions

CPE From Up to
cpe:2.3:a:ruby-lang:ruby:*:*:*:*:*:*:*:* 1.8.7-334 (including)
cpe:2.3:a:ruby-lang:ruby:1.8.7:p22:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7:p71:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7:p72:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-160:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-173:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-248:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-249:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-299:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-302:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-330:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.8.7-p21:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.9:*:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.9:r18423:*:*:*:*:*:*
cpe:2.3:a:ruby-lang:ruby:1.9.0:*:*:*:*:*:*:*


References to Advisories, Solutions, and Tools