All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Maxim Zhukov <crazycdeveloper@gmail.com>
Cc: Eric Biggers <ebiggers@google.com>,
	stable@vger.kernel.org, David Howells <dhowells@redhat.com>,
	Herbert Xu <herbert@gondor.apana.org.au>,
	Maxim Zhukov <mussitantesmortem@gmail.com>
Subject: Re: [PATCH] crypto: pcbc - remove bogus memcpy()s with src == dest
Date: Wed, 20 Mar 2019 19:05:04 +0100	[thread overview]
Message-ID: <20190320180504.GA5747@kroah.com> (raw)
In-Reply-To: <20190320173207.18266-1-mussitantesmortem@gmail.com>

On Wed, Mar 20, 2019 at 08:32:07PM +0300, Maxim Zhukov wrote:
> From: Eric Biggers <ebiggers@google.com>
> 
> commit 251b7aea34ba3c4d4fdfa9447695642eb8b8b098 upstream
> 
> The memcpy()s in the PCBC implementation use walk->iv as both the source
> and destination, which has undefined behavior.  These memcpy()'s are
> actually unneeded, because walk->iv is already used to hold the previous
> plaintext block XOR'd with the previous ciphertext block.  Thus,
> walk->iv is already updated to its final value.
> 
> So remove the broken and unnecessary memcpy()s.
> 
> Fixes: 91652be5d1b9 ("[CRYPTO] pcbc: Add Propagated CBC template")
> Cc: <stable@vger.kernel.org> # v2.6.21+
> Cc: David Howells <dhowells@redhat.com>
> Signed-off-by: Eric Biggers <ebiggers@google.com>
> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
> Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com>
> ---
>  crypto/pcbc.c | 14 ++++----------
>  1 file changed, 4 insertions(+), 10 deletions(-)

Thanks for all of the backports, now queued up.

greg k-h

      reply	other threads:[~2019-03-20 18:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-20 16:19 FAILED: patch "[PATCH] crypto: pcbc - remove bogus memcpy()s with src == dest" failed to apply to 4.14-stable tree gregkh
2019-03-20 17:32 ` [PATCH] crypto: pcbc - remove bogus memcpy()s with src == dest Maxim Zhukov
2019-03-20 18:05   ` Greg KH [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=20190320180504.GA5747@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=crazycdeveloper@gmail.com \
    --cc=dhowells@redhat.com \
    --cc=ebiggers@google.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=mussitantesmortem@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.