Input validation error in PHP - CVE-2008-2107

 

Input validation error in PHP - CVE-2008-2107

Published: October 11, 2018 / Updated: June 8, 2025


Vulnerability identifier: #VU110344
CSH Severity: Medium
CVSS v4: 6.9 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N]
CVE-ID: CVE-2008-2107
CWE-ID: CWE-20
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote non-authenticated attacker to read and manipulate data.

The GENERATE_SEED macro in PHP 4.x before 4.4.8 and 5.x before 5.2.5, when running on 32-bit systems, performs a multiplication using values that can produce a zero seed in rare circumstances, which allows context-dependent attackers to predict subsequent values of the rand and mt_rand functions and possibly bypass protection mechanisms that rely on an unknown initial seed.


Affected software

PHP
Ubuntu
libapache2-mod-php5 (Ubuntu package)
php5-cgi (Ubuntu package)
php5-curl (Ubuntu package)
php5-cli (Ubuntu package)

How to mitigate CVE-2008-2107

Install update from vendor's website.

PHP - update to 5.2.5
libapache2-mod-php5 (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.12, 5.2.1-0ubuntu1.6, 5.2.3-1ubuntu6.4, 5.2.4-2ubuntu5.3
php5-cgi (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.12, 5.2.1-0ubuntu1.6, 5.2.3-1ubuntu6.4, 5.2.4-2ubuntu5.3
php5-curl (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.12, 5.2.1-0ubuntu1.6, 5.2.3-1ubuntu6.4, 5.2.4-2ubuntu5.3
php5-cli (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.12, 5.2.1-0ubuntu1.6, 5.2.3-1ubuntu6.4, 5.2.4-2ubuntu5.3

External References

Related Security Bulletins