Lines Matching refs:final
123 hex += encrypt.final('hex');
154 msg += decrypt.final(outputEncoding);
157 // Assert that final throws if input data could not be verified!
158 assert.throws(function() { decrypt.final('hex'); }, errMessages.auth);
172 hex += encrypt.final('hex');
193 msg += decrypt.final('ascii');
196 // Assert that final throws if input data could not be verified!
197 assert.throws(function() { decrypt.final('ascii'); }, errMessages.auth);
231 encrypt.final();
288 cipher.final();
314 decipher.final(),
519 // Test that final() throws in CCM mode when no authentication tag is provided.
535 decrypt.final();
548 assert.strictEqual(decrypt.final('hex'), '');
558 encrypt.final();
562 // final() in GCM or OCB mode.
573 const ciphertext = Buffer.concat([cipher.update(plain), cipher.final()]);
587 const resultFinal = decipher.final();
604 const ciphertext = Buffer.concat([cipher.update(plain), cipher.final()]);
615 decipher.final(),
680 cipher.final();
712 const ciphertext = Buffer.concat([cipher.update('foo'), cipher.final()]);
722 // ChaCha20 is a stream cipher so we do not need to call final() to obtain
730 decipher.final();
773 cipher.final(),
783 decipher.setAuthTag(authTag).final(),
806 cipher.final(),
817 decipher.final();