| @@ -128,9 +128,9 @@ | ||
| 128 | 128 | $cipherTextStream = Psr7\Utils::streamFor($cipherText); |
| 129 | 129 | switch ($cipherOptions['Cipher']) { |
| 130 | 130 | case 'gcm': |
| 131 | 131 | $cipherOptions['Tag'] = $this->getTagFromCiphertextStream($cipherTextStream, $cipherOptions['TagLength']); |
| 132 | - return new AesGcmDecryptingStream($this->getStrippedCiphertextStream($cipherTextStream, $cipherOptions['TagLength']), $cek, $cipherOptions['Iv'], $cipherOptions['Tag'], $cipherOptions['Aad'] = isset($cipherOptions['Aad']) ? $cipherOptions['Aad'] : null, $cipherOptions['TagLength'] ?: null, $cipherOptions['KeySize']); | |
| 132 | + return new AesGcmDecryptingStream($this->getStrippedCiphertextStream($cipherTextStream, $cipherOptions['TagLength']), $cek, $cipherOptions['Iv'], $cipherOptions['Tag'], $cipherOptions['Aad'] = isset($cipherOptions['Aad']) ? $cipherOptions['Aad'] : '', $cipherOptions['TagLength'] ?: null, $cipherOptions['KeySize']); | |
| 133 | 133 | default: |
| 134 | 134 | $cipherMethod = $this->buildCipherMethod($cipherOptions['Cipher'], $cipherOptions['Iv'], $cipherOptions['KeySize']); |
| 135 | 135 | return new AesDecryptingStream($cipherTextStream, $cek, $cipherMethod); |
| 136 | 136 | } |