[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1d8eb859-1d41-32e1-98b8-3ddd60e2e0ab@suse.de>
Date: Wed, 1 Dec 2021 08:34:16 +0100
From: Hannes Reinecke <hare@...e.de>
To: Nicolai Stange <nstange@...e.de>,
Herbert Xu <herbert@...dor.apana.org.au>,
"David S. Miller" <davem@...emloft.net>
Cc: Stephan Müller <smueller@...onox.de>,
Torsten Duwe <duwe@...e.de>, Zaibo Xu <xuzaibo@...wei.com>,
Giovanni Cabiddu <giovanni.cabiddu@...el.com>,
David Howells <dhowells@...hat.com>,
Jarkko Sakkinen <jarkko@...nel.org>,
linux-crypto@...r.kernel.org, linux-kernel@...r.kernel.org,
qat-linux@...el.com, keyrings@...r.kernel.org
Subject: Re: [PATCH 17/18] crypto: dh - try to match domain parameters to a
known safe-prime group
On 12/1/21 1:48 AM, Nicolai Stange wrote:
> A subsequent patch will make the DH implementation to reject any input
> domain parameter set with ->group_id == dh_group_id_unknown in FIPS mode.
> However, as the keyctl(KEYCTL_DH_COMPUTE) implementation simply passes
> forward keys from userspace, it does not (and cannot) set ->group_id to
> anything else than dh_group_id_unknown.
>
> In order to still allow for keyctl(KEYCTL_DH_COMPUTE) to work on approved
> domain parameters passed in from userspace in FIPS mode, make
> crypto_dh_decode_key() to compare them against any of the known groups and
> set ->group_id upon having found a match, if any.
>
> Signed-off-by: Nicolai Stange <nstange@...e.de>
> ---
> crypto/dh_helper.c | 33 +++++++++++++++++++++++++++++++++
> 1 file changed, 33 insertions(+)
>
Reviewed-by: Hannes Reinecke <hare@...e.de>
Cheers,
Hannes
--
Dr. Hannes Reinecke Kernel Storage Architect
hare@...e.de +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer
Powered by blists - more mailing lists