fix PHP4 compatibility issue

This commit is contained in:
terrafrost 2019-09-22 10:19:38 -05:00
parent 11532ba414
commit e73f1ec910

View File

@ -1603,12 +1603,12 @@ class Crypt_RSA
&$components['primes'][2]
);
foreach ($values as &$value) {
for ($i = 0; $i < count($values); $i++) {
extract(unpack('Nlength', $this->_string_shift($paddedKey, 4)));
if (strlen($paddedKey) < $length) {
return false;
}
$value = new Math_BigInteger($this->_string_shift($paddedKey, $length), -256);
$values[$i] = new Math_BigInteger($this->_string_shift($paddedKey, $length), -256);
}
extract(unpack('Nlength', $this->_string_shift($paddedKey, 4)));