From: Eric Biggers <ebiggers@kernel.org>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Linux Crypto Mailing List <linux-crypto@vger.kernel.org>
Subject: Re: [PATCH 1/2] crypto: api - Fix race condition in crypto_spawn_alg
Date: Tue, 10 Dec 2019 19:38:28 -0800 [thread overview]
Message-ID: <20191211033828.GH732@sol.localdomain> (raw)
In-Reply-To: <E1idarb-0002qH-Va@gondobar>
On Sat, Dec 07, 2019 at 10:15:15PM +0800, Herbert Xu wrote:
> The function crypto_spawn_alg is racy because it drops the lock
> before shooting the dying algorithm. The algorithm could disappear
> altogether before we shoot it.
>
> This patch fixes it by moving the shooting into the locked section.
>
> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Does this need Fixes and Cc stable tags?
- Eric
next prev parent reply other threads:[~2019-12-11 3:38 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-06 14:39 [PATCH 0/2] crypto: api - Fix spawn races Herbert Xu
2019-12-06 14:39 ` [PATCH 1/2] crypto: api - Fix race condition in crypto_spawn_alg Herbert Xu
2019-12-06 14:39 ` [PATCH 2/2] crypto: api - Do not zap spawn->alg Herbert Xu
2019-12-06 22:50 ` Eric Biggers
2019-12-07 3:40 ` Herbert Xu
2019-12-07 14:33 ` [PATCH] crypto: api - Add more comments to crypto_remove_spawns Herbert Xu
2019-12-07 14:15 ` [v2 PATCH 0/2] crypto: api - Fix spawn races Herbert Xu
2019-12-07 14:15 ` [PATCH 1/2] crypto: api - Fix race condition in crypto_spawn_alg Herbert Xu
2019-12-11 3:38 ` Eric Biggers [this message]
2019-12-11 5:41 ` Herbert Xu
2019-12-07 14:15 ` [PATCH 2/2] crypto: api - Do not zap spawn->alg Herbert Xu
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=20191211033828.GH732@sol.localdomain \
--to=ebiggers@kernel.org \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@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;
as well as URLs for NNTP newsgroup(s).