diff options
author | Stephan Mueller <smueller@chronox.de> | 2016-10-21 04:59:24 +0200 |
---|---|---|
committer | Jonathan Corbet <corbet@lwn.net> | 2016-12-13 16:38:06 -0700 |
commit | 239a79b2f922a0614334cef0aab2f8a23a4e54f9 (patch) | |
tree | c10efca763a4f4a13b96b4123498d33f887104c4 | |
parent | 736d25df198dddeec82f61fee130f7d0e4212a9c (diff) | |
download | linux-crypto-239a79b2f922a0614334cef0aab2f8a23a4e54f9.tar.gz linux-crypto-239a79b2f922a0614334cef0aab2f8a23a4e54f9.zip |
crypto: doc - clarify AEAD memory structure
The previous description have been misleading and partially incorrect.
Reported-by: Harsh Jain <harshjain.prof@gmail.com>
Signed-off-by: Stephan Mueller <smueller@chronox.de>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to '')
-rw-r--r-- | crypto/algif_aead.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/crypto/algif_aead.c b/crypto/algif_aead.c index 80a0f1a7..a0d83777 100644 --- a/crypto/algif_aead.c +++ b/crypto/algif_aead.c @@ -551,18 +551,8 @@ static int aead_recvmsg_sync(struct socket *sock, struct msghdr *msg, int flags) lock_sock(sk); /* - * AEAD memory structure: For encryption, the tag is appended to the - * ciphertext which implies that the memory allocated for the ciphertext - * must be increased by the tag length. For decryption, the tag - * is expected to be concatenated to the ciphertext. The plaintext - * therefore has a memory size of the ciphertext minus the tag length. - * - * The memory structure for cipher operation has the following - * structure: - * AEAD encryption input: assoc data || plaintext - * AEAD encryption output: cipherntext || auth tag - * AEAD decryption input: assoc data || ciphertext || auth tag - * AEAD decryption output: plaintext + * Please see documentation of aead_request_set_crypt for the + * description of the AEAD memory structure expected from the caller. */ if (ctx->more) { |