Merge remote-tracking branch 'g5-update/php81' into php81-jw

This commit is contained in:
kit rio
2022-05-31 17:20:53 +09:00
106 changed files with 7866 additions and 7439 deletions

View File

@ -66,7 +66,7 @@ class ntlm_sasl_client_class
public function NTLMResponse($challenge, $password)
{
$unicode = $this->ASCIIToUnicode($password);
$md4 = mhash(MHASH_MD4, $unicode);
$md4 = hash('md4', $unicode, true);
$padded = $md4 . str_repeat(chr(0), 21 - strlen($md4));
$iv_size = mcrypt_get_iv_size(MCRYPT_DES, MCRYPT_MODE_ECB);
$iv = mcrypt_create_iv($iv_size, MCRYPT_RAND);

View File

@ -8336,8 +8336,10 @@ class HTMLPurifier_PropertyListIterator extends FilterIterator
/**
* @return bool
*
* {@inheritdoc}
*/
#[ReturnTypeWillChange]
#[\ReturnTypeWillChange]
public function accept()
{
$key = $this->getInnerIterator()->key();
@ -8455,6 +8457,8 @@ class HTMLPurifier_StringHash extends ArrayObject
* Retrieves a value, and logs the access.
* @param mixed $index
* @return mixed
*
* {@inheritdoc}
*/
#[\ReturnTypeWillChange]
public function offsetGet($index)

View File

@ -171,10 +171,10 @@ class KCAPTCHA{
if($sx<0 || $sy<0 || $sx>=$width-1 || $sy>=$height-1){
continue;
}else{
$color=imagecolorat($img, $sx, $sy) & 0xFF;
$color_x=imagecolorat($img, $sx+1, $sy) & 0xFF;
$color_y=imagecolorat($img, $sx, $sy+1) & 0xFF;
$color_xy=imagecolorat($img, $sx+1, $sy+1) & 0xFF;
$color=imagecolorat($img, (int)$sx, (int)$sy) & 0xFF;
$color_x=imagecolorat($img, (int)$sx+1, (int)$sy) & 0xFF;
$color_y=imagecolorat($img, (int)$sx, (int)$sy+1) & 0xFF;
$color_xy=imagecolorat($img, (int)$sx+1, (int)$sy+1) & 0xFF;
}
if($color==255 && $color_x==255 && $color_y==255 && $color_xy==255){
@ -204,7 +204,7 @@ class KCAPTCHA{
$newblue=$newcolor0*$foreground_color[2]+$newcolor*$background_color[2];
}
imagesetpixel($img2, $x, $y, imagecolorallocate($img2, $newred, $newgreen, $newblue));
imagesetpixel($img2, (int)$x, (int)$y, imagecolorallocate($img2, (int)$newred, (int)$newgreen, (int)$newblue));
}
}