Clarify the usage of decryption API.

This commit is contained in:
Sean Bowe 2016-04-28 17:06:08 -06:00
parent 984bdd88f1
commit 70ac6ce2ee
1 changed files with 2 additions and 0 deletions

View File

@ -121,6 +121,8 @@ typename NoteDecryption<MLEN>::Plaintext NoteDecryption<MLEN>::decrypt
NoteDecryption<MLEN>::Plaintext plaintext; NoteDecryption<MLEN>::Plaintext plaintext;
// Message length is always NOTEENCRYPTION_AUTH_BYTES less than
// the ciphertext length.
if (crypto_aead_chacha20poly1305_ietf_decrypt(plaintext.begin(), NULL, if (crypto_aead_chacha20poly1305_ietf_decrypt(plaintext.begin(), NULL,
NULL, NULL,
ciphertext.begin(), NoteDecryption<MLEN>::CLEN, ciphertext.begin(), NoteDecryption<MLEN>::CLEN,