Commit f8b10296 authored by webchick's avatar webchick
Browse files

#938614 follow-up by chx: Abort abort\! Back to 5.2.4.

parent b5e43a99
......@@ -19,7 +19,7 @@
/**
* Minimum supported version of PHP.
*/
define('DRUPAL_MINIMUM_PHP', '5.2.5');
define('DRUPAL_MINIMUM_PHP', '5.2.4');
/**
* Minimum recommended value of PHP memory_limit.
......
......@@ -1293,6 +1293,9 @@ final public static function getLog($logging_key, $key = 'default') {
/**
* Gets the connection object for the specified database key and target.
*
* Note: do not use the setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE) on the
* returned object because of http://bugs.php.net/bug.php?id=43139.
*
* @param $target
* The database target name.
* @param $key
......
......@@ -77,6 +77,15 @@ function system_requirements($phase) {
// If PHP is old, it's not safe to continue with the requirements check.
return $requirements;
}
// Check that htmlspecialchars() is secure if the site is running any PHP
// version older than 5.2.5. We don't simply require 5.2.5, because Ubuntu
// 8.04 ships with PHP 5.2.4, but includes the necessary security patch.
elseif (version_compare($phpversion, '5.2.5') < 0 && strlen(@htmlspecialchars(chr(0xC0) . chr(0xAF), ENT_QUOTES, 'UTF-8'))) {
$requirements['php']['description'] = $t('Your PHP installation is too old. Drupal requires at least PHP 5.2.5, or PHP @version with the htmlspecialchars security patch backported.', array('@version' => DRUPAL_MINIMUM_PHP));
$requirements['php']['severity'] = REQUIREMENT_ERROR;
// If PHP is old, it's not safe to continue with the requirements check.
return $requirements;
}
// Test PHP register_globals setting.
$requirements['php_register_globals'] = array(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment