BUG-15561 Cambiar el algoritmo o metodo de cifrado... SOLVED

- It don't have the functionality.
- A function was add in class bootstrap hasPassword.
- a function was add in class enterprise.
This commit is contained in:
Marco Antonio Nina
2014-09-22 09:58:50 -04:00
parent c4f0578bd1
commit 48d963a033
23 changed files with 2182 additions and 1937 deletions

View File

@@ -2859,5 +2859,33 @@ class Bootstrap
die();
}
}
public function hasPassword($pass, $previous=false) {
$passEncrypt = md5($pass);
try {
require_once PATH_CORE .'methods' . PATH_SEP .'enterprise/enterprise.php';
$passEncrypt = enterprisePlugin::hashPassword($pass, $previous);
} catch (Exception $e) {
}
error_log('hasPassword bootstrap ' . $passEncrypt);
return $passEncrypt;
}
public function verifyHashPassword ($pass, $userPass)
{
//$verify = Bootstrap::hasPassword($pass);
error_log('contraseña config...');
if (Bootstrap::hasPassword($pass) == $userPass) {
return true;
}
error_log('contraseña anterior...');
if (Bootstrap::hasPassword($pass, true) == $userPass) {
return true;
}
return false;
}
}