mirror of
https://github.com/phpseclib/phpseclib.git
synced 2024-12-25 11:20:03 +00:00
unset($block);
Optional but increase quality Score
This commit is contained in:
parent
0efd3176d8
commit
80c7ee9eaf
@ -326,7 +326,7 @@ class Salsa20 extends StreamCipher
|
||||
foreach ($blocks as &$block) {
|
||||
$block ^= static::salsa20($this->p1 . pack('V', $i++) . $this->p2);
|
||||
}
|
||||
|
||||
unset($block);
|
||||
return implode('', $blocks);
|
||||
}
|
||||
|
||||
@ -366,6 +366,7 @@ class Salsa20 extends StreamCipher
|
||||
foreach ($blocks as &$block) {
|
||||
$block ^= static::salsa20($this->p1 . pack('V', $buffer['counter']++) . $this->p2);
|
||||
}
|
||||
unset($block);
|
||||
}
|
||||
$encrypted = implode('', $blocks);
|
||||
$temp = static::salsa20($this->p1 . pack('V', $buffer['counter']++) . $this->p2);
|
||||
@ -388,6 +389,7 @@ class Salsa20 extends StreamCipher
|
||||
foreach ($blocks as &$block) {
|
||||
$block ^= static::salsa20($this->p1 . pack('V', $buffer['counter']++) . $this->p2);
|
||||
}
|
||||
unset($block);
|
||||
$ciphertext .= implode('', $blocks);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user