1
0
Fork 0
mirror of https://github.com/Yetangitu/ampache synced 2025-10-04 02:09:23 +02:00

add a check for the sha256() hash algo

This commit is contained in:
Karl 'vollmerk' Vollmer 2008-12-28 23:15:08 +00:00
parent fb36d75ace
commit ebcc2e6bbe

View file

@ -76,10 +76,18 @@ function check_database_inserted($dbh,$db_name) {
*/
function check_php_ver($level=0) {
if (strcmp('5.1.0',phpversion()) > 0) {
if (strcmp('5.1.2',phpversion()) > 0) {
return false;
}
// Make sure that they have the sha256() algo installed
if (!function_exists('hash_algos')) { return false; }
$algos = hash_algos();
if (!in_array('sha256',$algos)) {
return false;
}
return true;
} // check_php_ver