mirror of
https://github.com/danog/tgseclib.git
synced 2025-01-22 22:11:13 +01:00
RSA: use hash_equals if available
This commit is contained in:
parent
f111bf94b6
commit
b5b763b3f2
@ -2301,6 +2301,10 @@ class Crypt_RSA
|
||||
*/
|
||||
function _equals($x, $y)
|
||||
{
|
||||
if (function_exists('hash_equals')) {
|
||||
return hash_equals($x, $y);
|
||||
}
|
||||
|
||||
if (strlen($x) != strlen($y)) {
|
||||
return false;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user