[v4,04/12] cryptodev: clarify usage of private key in dh
Checks
Commit Message
- Clarified usage of private key in Diffie-Hellman.
CSRNG capable device should generate private key and then
use it for public key generation.
Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
---
lib/cryptodev/rte_crypto_asym.h | 5 +++++
1 file changed, 5 insertions(+)
Comments
> -----Original Message-----
> From: Kusztal, ArkadiuszX <arkadiuszx.kusztal@intel.com>
> Sent: Tuesday, May 31, 2022 5:05 AM
> To: dev@dpdk.org
> Cc: gakhil@marvell.com; Zhang, Roy Fan <roy.fan.zhang@intel.com>; Kusztal,
> ArkadiuszX <arkadiuszx.kusztal@intel.com>
> Subject: [PATCH v4 04/12] cryptodev: clarify usage of private key in dh
>
> - Clarified usage of private key in Diffie-Hellman.
> CSRNG capable device should generate private key and then
> use it for public key generation.
>
> Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
> ---
Acked-by: Fan Zhang <roy.fan.zhang@intel.com>
@@ -416,6 +416,11 @@ struct rte_crypto_dh_op_param {
* Input - private key, when dh xform ke_type is one of:
* RTE_CRYPTO_ASYM_KE_PUB_KEY_GENERATE,
* RTE_CRYPTO_ASYM_KE_SHARED_SECRET_COMPUTE.
+ *
+ * In case priv_key.length is 0 and xform type is set with
+ * RTE_CRYPTO_ASYM_KE_PUB_KEY_GENERATE, CSRNG capable
+ * device will generate a private key and use it for public
+ * key generation.
*/
rte_crypto_uint shared_secret;