mirror of
https://github.com/phpseclib/phpseclib.git
synced 2024-11-05 21:17:53 +00:00
Crypt/Base: fix CTR mode with continuous buffer with non-eval PHP
This commit is contained in:
parent
e69380bfd1
commit
4d66eeb6a4
@ -937,8 +937,8 @@ class Crypt_Base
|
||||
$block = substr($plaintext, $i, $block_size);
|
||||
if (strlen($block) > strlen($buffer['ciphertext'])) {
|
||||
$buffer['ciphertext'].= $this->_encryptBlock($xor);
|
||||
$this->_increment_str($xor);
|
||||
}
|
||||
$this->_increment_str($xor);
|
||||
$key = $this->_string_shift($buffer['ciphertext'], $block_size);
|
||||
$ciphertext.= $block ^ $key;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user