Linux cryptographic layer development
 help / color / mirror / Atom feed
From: Herbert Xu <herbert@gondor.apana.org.au>
To: "Ondrej Mosnáček" <omosnacek@gmail.com>
Cc: "David S. Miller" <davem@davemloft.net>,
	linux-crypto@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH] crypto: skcipher - Fix skcipher_walk_aead_common
Date: Sat, 25 Nov 2017 11:13:58 +1100	[thread overview]
Message-ID: <20171125001358.GA20780@gondor.apana.org.au> (raw)
In-Reply-To: <CAAUqJDtvTVchrm2kaU06EWDXA-KY3FLsyq-K_dRO6Hec7xqV+g@mail.gmail.com>

On Fri, Nov 24, 2017 at 11:53:53AM +0100, Ondrej Mosnáček wrote:
> (I accidentally hit "reply" instead of "reply all", so resending)
> 
> 2017-11-24 6:07 GMT+01:00 Herbert Xu <herbert@gondor.apana.org.au>:
> > On Thu, Nov 23, 2017 at 01:49:06PM +0100, Ondrej Mosnacek wrote:
> >> diff --git a/crypto/skcipher.c b/crypto/skcipher.c
> >> index 4faa0fd53b0c..6c45ed536664 100644
> >> --- a/crypto/skcipher.c
> >> +++ b/crypto/skcipher.c
> >> @@ -517,6 +517,9 @@ static int skcipher_walk_aead_common(struct skcipher_walk *walk,
> >>       scatterwalk_copychunks(NULL, &walk->in, req->assoclen, 2);
> >>       scatterwalk_copychunks(NULL, &walk->out, req->assoclen, 2);
> >>
> >> +     scatterwalk_done(&walk->in, 0, walk->total);
> >> +     scatterwalk_done(&walk->out, 0, walk->total);
> >
> > That should be 1 instead of 0 for walk->out.
> >
> > Could you please fix and resubmit?
> 
> Since the associated data is not written, just skipped, I believe 0 is
> more appropriate. scatterwalk_copychunks(..., 2) also calls
> scatterwalk_pagedone() with out=0 internally.

Thanks for the explanation.

Patch applied.

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

      reply	other threads:[~2017-11-25  0:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-23 12:49 [PATCH] crypto: skcipher - Fix skcipher_walk_aead_common Ondrej Mosnacek
2017-11-24  5:07 ` Herbert Xu
2017-11-24 10:53   ` Ondrej Mosnáček
2017-11-25  0:13     ` Herbert Xu [this message]

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=20171125001358.GA20780@gondor.apana.org.au \
    --to=herbert@gondor.apana.org.au \
    --cc=davem@davemloft.net \
    --cc=linux-crypto@vger.kernel.org \
    --cc=omosnacek@gmail.com \
    --cc=stable@vger.kernel.org \
    /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