From: Herbert Xu <herbert@gondor.apana.org.au>
To: Stephan Mueller <smueller@chronox.de>
Cc: 'LKML' <linux-kernel@vger.kernel.org>, linux-crypto@vger.kernel.org
Subject: Re: [PATCH] crypto: AEAD: add check for presence of auth tag
Date: Mon, 5 Jan 2015 21:19:01 +1100 [thread overview]
Message-ID: <20150105101901.GA24736@gondor.apana.org.au> (raw)
In-Reply-To: <15957213.Wu7Np8vQse@tachyon.chronox.de>
On Tue, Dec 30, 2014 at 10:16:03PM +0100, Stephan Mueller wrote:
> The AEAD decryption operation requires the authentication tag to be
> present as part of the cipher text buffer. The added check verifies that
> the caller provides a cipher text buffer with at least the
> authentication tag.
>
> As the cipher text is provided as a scatterlist, loop through the
> scatterlist until we know we have sufficient cipher text bytes to invoke
> the AEAD decryption operation.
There is no need to vet the scatterlist. For kernel users it's
up to them to ensure that the length is valid with respect to the
sg list.
For the user-space interface obviously you should ensure that a
valid length is supplied.
Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
next prev parent reply other threads:[~2015-01-05 10:19 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-30 21:16 [PATCH] crypto: AEAD: add check for presence of auth tag Stephan Mueller
2015-01-05 10:19 ` Herbert Xu [this message]
2015-01-05 10:26 ` Stephan Mueller
2015-01-05 10:39 ` Herbert Xu
2015-01-05 10:53 ` Stephan Mueller
2015-01-05 10:55 ` Herbert Xu
2015-01-05 11:00 ` Stephan Mueller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150105101901.GA24736@gondor.apana.org.au \
--to=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=smueller@chronox.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox