* [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps
@ 2020-04-24 13:40 Corentin Labbe
2020-04-24 13:40 ` [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512 Corentin Labbe
` (3 more replies)
0 siblings, 4 replies; 7+ messages in thread
From: Corentin Labbe @ 2020-04-24 13:40 UTC (permalink / raw)
To: davem, herbert; +Cc: linux-crypto, linux-kernel, Corentin Labbe
Hello
Fix serie try to fix some DRBG depencies in Kconfig
Change since v2:
- added patch #2
Changes since v1:
- Updated commit message with recursive dependency
Corentin Labbe (3):
crypto: drbg: DRBG should select SHA512
crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV
crypto: drbg: DRBG_CTR should select CTR
crypto/Kconfig | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
--
2.26.2
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512
2020-04-24 13:40 [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Corentin Labbe
@ 2020-04-24 13:40 ` Corentin Labbe
2020-04-30 4:43 ` Herbert Xu
2020-04-24 13:40 ` [PATCH v3 2/3] crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV Corentin Labbe
` (2 subsequent siblings)
3 siblings, 1 reply; 7+ messages in thread
From: Corentin Labbe @ 2020-04-24 13:40 UTC (permalink / raw)
To: davem, herbert; +Cc: linux-crypto, linux-kernel, Corentin Labbe
Since DRBG could use SHA384/SHA512, it should select it.
Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
---
crypto/Kconfig | 2 ++
1 file changed, 2 insertions(+)
diff --git a/crypto/Kconfig b/crypto/Kconfig
index c24a47406f8f..6d27fc6a7bf5 100644
--- a/crypto/Kconfig
+++ b/crypto/Kconfig
@@ -1810,10 +1810,12 @@ config CRYPTO_DRBG_HMAC
default y
select CRYPTO_HMAC
select CRYPTO_SHA256
+ select CRYPTO_SHA512
config CRYPTO_DRBG_HASH
bool "Enable Hash DRBG"
select CRYPTO_SHA256
+ select CRYPTO_SHA512
help
Enable the Hash DRBG variant as defined in NIST SP800-90A.
--
2.26.2
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v3 2/3] crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV
2020-04-24 13:40 [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Corentin Labbe
2020-04-24 13:40 ` [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512 Corentin Labbe
@ 2020-04-24 13:40 ` Corentin Labbe
2020-06-04 16:15 ` Eric Biggers
2020-04-24 13:40 ` [PATCH v3 3/3] crypto: drbg: DRBG_CTR should select CTR Corentin Labbe
2020-04-30 5:32 ` [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Herbert Xu
3 siblings, 1 reply; 7+ messages in thread
From: Corentin Labbe @ 2020-04-24 13:40 UTC (permalink / raw)
To: davem, herbert; +Cc: linux-crypto, linux-kernel, Corentin Labbe
As comment of the v2, Herbert said: "The SEQIV select from CTR is historical
and no longer necessary."
So let's get rid of it.
Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
---
crypto/Kconfig | 1 -
1 file changed, 1 deletion(-)
diff --git a/crypto/Kconfig b/crypto/Kconfig
index 6d27fc6a7bf5..a5936e967fe2 100644
--- a/crypto/Kconfig
+++ b/crypto/Kconfig
@@ -370,7 +370,6 @@ config CRYPTO_CFB
config CRYPTO_CTR
tristate "CTR support"
select CRYPTO_SKCIPHER
- select CRYPTO_SEQIV
select CRYPTO_MANAGER
help
CTR: Counter mode
--
2.26.2
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v3 3/3] crypto: drbg: DRBG_CTR should select CTR
2020-04-24 13:40 [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Corentin Labbe
2020-04-24 13:40 ` [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512 Corentin Labbe
2020-04-24 13:40 ` [PATCH v3 2/3] crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV Corentin Labbe
@ 2020-04-24 13:40 ` Corentin Labbe
2020-04-30 5:32 ` [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Herbert Xu
3 siblings, 0 replies; 7+ messages in thread
From: Corentin Labbe @ 2020-04-24 13:40 UTC (permalink / raw)
To: davem, herbert; +Cc: linux-crypto, linux-kernel, Corentin Labbe
if CRYPTO_DRBG_CTR is builtin and CTR is module, allocating such algo
will fail.
DRBG: could not allocate CTR cipher TFM handle: ctr(aes)
alg: drbg: Failed to reset rng
alg: drbg: Test 0 failed for drbg_pr_ctr_aes128
DRBG: could not allocate CTR cipher TFM handle: ctr(aes)
alg: drbg: Failed to reset rng
alg: drbg: Test 0 failed for drbg_nopr_ctr_aes128
DRBG: could not allocate CTR cipher TFM handle: ctr(aes)
alg: drbg: Failed to reset rng
alg: drbg: Test 0 failed for drbg_nopr_ctr_aes192
DRBG: could not allocate CTR cipher TFM handle: ctr(aes)
alg: drbg: Failed to reset rng
alg: drbg: Test 0 failed for drbg_nopr_ctr_aes256
So let's select CTR instead of just depend on it.
Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
---
crypto/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/crypto/Kconfig b/crypto/Kconfig
index a5936e967fe2..7c2c09a76173 100644
--- a/crypto/Kconfig
+++ b/crypto/Kconfig
@@ -1821,7 +1821,7 @@ config CRYPTO_DRBG_HASH
config CRYPTO_DRBG_CTR
bool "Enable CTR DRBG"
select CRYPTO_AES
- depends on CRYPTO_CTR
+ select CRYPTO_CTR
help
Enable the CTR DRBG variant as defined in NIST SP800-90A.
--
2.26.2
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512
2020-04-24 13:40 ` [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512 Corentin Labbe
@ 2020-04-30 4:43 ` Herbert Xu
0 siblings, 0 replies; 7+ messages in thread
From: Herbert Xu @ 2020-04-30 4:43 UTC (permalink / raw)
To: Corentin Labbe; +Cc: davem, linux-crypto, linux-kernel
On Fri, Apr 24, 2020 at 01:40:45PM +0000, Corentin Labbe wrote:
> Since DRBG could use SHA384/SHA512, it should select it.
>
> Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
> ---
> crypto/Kconfig | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/crypto/Kconfig b/crypto/Kconfig
> index c24a47406f8f..6d27fc6a7bf5 100644
> --- a/crypto/Kconfig
> +++ b/crypto/Kconfig
> @@ -1810,10 +1810,12 @@ config CRYPTO_DRBG_HMAC
> default y
> select CRYPTO_HMAC
> select CRYPTO_SHA256
> + select CRYPTO_SHA512
>
> config CRYPTO_DRBG_HASH
> bool "Enable Hash DRBG"
> select CRYPTO_SHA256
> + select CRYPTO_SHA512
> help
> Enable the Hash DRBG variant as defined in NIST SP800-90A.
The default hash drbg is sha256, the others are only optional.
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps
2020-04-24 13:40 [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Corentin Labbe
` (2 preceding siblings ...)
2020-04-24 13:40 ` [PATCH v3 3/3] crypto: drbg: DRBG_CTR should select CTR Corentin Labbe
@ 2020-04-30 5:32 ` Herbert Xu
3 siblings, 0 replies; 7+ messages in thread
From: Herbert Xu @ 2020-04-30 5:32 UTC (permalink / raw)
To: Corentin Labbe; +Cc: davem, linux-crypto, linux-kernel
On Fri, Apr 24, 2020 at 01:40:44PM +0000, Corentin Labbe wrote:
> Hello
>
> Fix serie try to fix some DRBG depencies in Kconfig
>
> Change since v2:
> - added patch #2
>
> Changes since v1:
> - Updated commit message with recursive dependency
>
> Corentin Labbe (3):
> crypto: drbg: DRBG should select SHA512
> crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV
> crypto: drbg: DRBG_CTR should select CTR
>
> crypto/Kconfig | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
Patches 2-3 applied. Thanks.
--
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v3 2/3] crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV
2020-04-24 13:40 ` [PATCH v3 2/3] crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV Corentin Labbe
@ 2020-06-04 16:15 ` Eric Biggers
0 siblings, 0 replies; 7+ messages in thread
From: Eric Biggers @ 2020-06-04 16:15 UTC (permalink / raw)
To: Corentin Labbe; +Cc: davem, herbert, linux-crypto, linux-kernel
On Fri, Apr 24, 2020 at 01:40:46PM +0000, Corentin Labbe wrote:
> As comment of the v2, Herbert said: "The SEQIV select from CTR is historical
> and no longer necessary."
>
> So let's get rid of it.
>
> Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
> ---
> crypto/Kconfig | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/crypto/Kconfig b/crypto/Kconfig
> index 6d27fc6a7bf5..a5936e967fe2 100644
> --- a/crypto/Kconfig
> +++ b/crypto/Kconfig
> @@ -370,7 +370,6 @@ config CRYPTO_CFB
> config CRYPTO_CTR
> tristate "CTR support"
> select CRYPTO_SKCIPHER
> - select CRYPTO_SEQIV
> select CRYPTO_MANAGER
> help
> CTR: Counter mode
Shouldn't this patch also have added 'select CRYPTO_SEQIV' to INET_ESP and
INET6_ESP? Or is the intent to make people explicitly select CRYPTO_SEQIV?
- Eric
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2020-06-04 16:15 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-24 13:40 [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Corentin Labbe
2020-04-24 13:40 ` [PATCH v3 1/3] crypto: drbg: DRBG should select SHA512 Corentin Labbe
2020-04-30 4:43 ` Herbert Xu
2020-04-24 13:40 ` [PATCH v3 2/3] crypto: CRYPTO_CTR no longer need CRYPTO_SEQIV Corentin Labbe
2020-06-04 16:15 ` Eric Biggers
2020-04-24 13:40 ` [PATCH v3 3/3] crypto: drbg: DRBG_CTR should select CTR Corentin Labbe
2020-04-30 5:32 ` [PATCH v3 0/3] crypto: fix some DRBG Kconfig deps Herbert Xu
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).