Code Injection in PHP - CVE-2010-1868

 

Code Injection in PHP - CVE-2010-1868

Published: May 11, 2010 / Updated: June 8, 2025


Vulnerability identifier: #VU110308
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-2010-1868
CWE-ID: CWE-94
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 (1) sqlite_single_query and (2) sqlite_array_query functions in ext/sqlite/sqlite.c in PHP 5.2 through 5.2.13 and 5.3 through 5.3.2 allow context-dependent attackers to execute arbitrary code by calling these functions with an empty SQL query, which triggers access of uninitialized memory.


Affected software

PHP
Gentoo Linux
Ubuntu
php5-cli (Ubuntu package)
php5-cgi (Ubuntu package)
libapache2-mod-php5 (Ubuntu package)
dev-lang/php

How to mitigate CVE-2010-1868

Install update from vendor's website.

PHP - addressed in versions 5.2.14, 5.3.3
php5-cli (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.19, 5.2.4-2ubuntu5.12, 5.2.6.dfsg.1-3ubuntu4.6, 5.2.10.dfsg.1-2ubuntu6.5, 5.3.2-1ubuntu4.5
php5-cgi (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.19, 5.2.4-2ubuntu5.12, 5.2.6.dfsg.1-3ubuntu4.6, 5.2.10.dfsg.1-2ubuntu6.5, 5.3.2-1ubuntu4.5
libapache2-mod-php5 (Ubuntu package) - addressed in versions 5.1.2-1ubuntu3.19, 5.2.4-2ubuntu5.12, 5.2.6.dfsg.1-3ubuntu4.6, 5.2.10.dfsg.1-2ubuntu6.5, 5.3.2-1ubuntu4.5
dev-lang/php - update to 5.3.8

External References

Related Security Bulletins