DPDK patches and discussions
 help / color / mirror / Atom feed
From: Anoob Joseph <anoobj@marvell.com>
To: "Kusztal, ArkadiuszX" <arkadiuszx.kusztal@intel.com>,
	Akhil Goyal <gakhil@marvell.com>, "dev@dpdk.org" <dev@dpdk.org>,
	Kiran Kumar Kokkilagadda <kirankumark@marvell.com>
Cc: "Zhang, Roy Fan" <roy.fan.zhang@intel.com>,
	Umesh Kartha <ukartha@marvell.com>,
	Ramkumar Balu <rbalu@marvell.com>
Subject: RE: [EXT] [PATCH 11/40] cryptodev: remove asym crypto next xform
Date: Wed, 25 May 2022 07:05:53 +0000	[thread overview]
Message-ID: <PH0PR18MB46728E58279FF867A33A2886DFD69@PH0PR18MB4672.namprd18.prod.outlook.com> (raw)
In-Reply-To: <PH0PR11MB50131318FD5F0190870646D69FD69@PH0PR11MB5013.namprd11.prod.outlook.com>

Hi Arek, Akhil,

Please see inline.

Thanks,
Anoob

> -----Original Message-----
> From: Kusztal, ArkadiuszX <arkadiuszx.kusztal@intel.com>
> Sent: Wednesday, May 25, 2022 12:06 PM
> To: Akhil Goyal <gakhil@marvell.com>; dev@dpdk.org; Kiran Kumar
> Kokkilagadda <kirankumark@marvell.com>; Anoob Joseph
> <anoobj@marvell.com>
> Cc: Zhang, Roy Fan <roy.fan.zhang@intel.com>
> Subject: RE: [EXT] [PATCH 11/40] cryptodev: remove asym crypto next xform
> 
> 
> 
> > -----Original Message-----
> > From: Akhil Goyal <gakhil@marvell.com>
> > Sent: Wednesday, May 25, 2022 8:06 AM
> > To: Kusztal, ArkadiuszX <arkadiuszx.kusztal@intel.com>; dev@dpdk.org;
> > Kiran Kumar Kokkilagadda <kirankumark@marvell.com>; Anoob Joseph
> > <anoobj@marvell.com>
> > Cc: Zhang, Roy Fan <roy.fan.zhang@intel.com>
> > Subject: RE: [EXT] [PATCH 11/40] cryptodev: remove asym crypto next
> > xform
> >
> > > > > - removed asymnetric crypto xform next field.
> > > > > Rationale behind having chaining in symmetric crypto was a fact
> > > > > that encryption and authentication are usually done on the same
> > > > > set of data independent of algorithm.
> > > > > HW usually will be able to handle it in one PCI call.
> > > > > In asymmetric there is no such relation between algorithms,
> > > > > therefore next field would be useless.
> > > > >
> > > > > Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
> > > >
> > > > Please check documentation "doc/guides/prog_guide/cryptodev_lib.rst"
> > > > Not all asymmetric crypto xforms are supported for chaining.
> > > > Currently supported asymmetric crypto chaining is Diffie-Hellman
> > > > private key generation followed by public generation.
> > > [Arek] And why do chaining when this can be done even with one bit flag.
> > >
> > I believe it is OK to remove next. @Kiran Kumar Kokkilagadda/Anoob
> > please confirm.
> >
> > If we are removing it, then documentation should be in sync.
> [Arek] - although, we may keep it for now, I am not dropping it in v2. DH priv +
> pub can be done with priv_key.len = 0 -> similar as 'k' in ecdsa when k.data =
> NULL.
> But I do not see any situation for now it will be  useful, it may be dropped later if
> not application found.
> >
> > > Also, currently API does not support chaining of
> > > > symmetric and asymmetric crypto xforms.
> > > [Arek] - This is one unlikely scenario to combine symmetric and
> > > asymmetric. One I can think of was once proposed DH + DSA
> > > integration for random number. But not much else, although we can
> > > keep it around for a
> > while.
> >
> > Yes it is highly unlikely to use this combination.

[Anoob] We may need this support when we add EdDSA support. That would involve a asymmetric operation after hash is generated (symmetric). 
https://en.wikipedia.org/wiki/EdDSA#Ed25519

And, asymmetric chaining may become useful when we have PMDs capable of doing more operations together (like the case with EdDSA). So my preference would be to retain the 'next' field in asym crypto xform.
 
> >
> > > >
> > > > > ---
> > > > >  lib/cryptodev/rte_crypto_asym.h | 2 --
> > > > >  1 file changed, 2 deletions(-)
> > > > >
> > > > > diff --git a/lib/cryptodev/rte_crypto_asym.h
> > > > > b/lib/cryptodev/rte_crypto_asym.h index 1652a434a5..b355cbe5fa
> > > > > 100644
> > > > > --- a/lib/cryptodev/rte_crypto_asym.h
> > > > > +++ b/lib/cryptodev/rte_crypto_asym.h
> > > > > @@ -492,8 +492,6 @@ struct rte_crypto_ecpm_op_param {
> > > > >   * Structure describing asym xforms.
> > > > >   */
> > > > >  struct rte_crypto_asym_xform {
> > > > > -	struct rte_crypto_asym_xform *next;
> > > > > -	/**< Pointer to next xform to set up xform chain.*/
> > > > >  	enum rte_crypto_asym_xform_type xform_type;
> > > > >  	/**< Asymmetric crypto transform */
> > > > >
> > > > > --
> > > > > 2.13.6


  reply	other threads:[~2022-05-25  7:06 UTC|newest]

Thread overview: 85+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-20  5:54 [PATCH 00/40] cryptodev: rsa, dh, ecdh changes Arek Kusztal
2022-05-20  5:54 ` [PATCH 01/40] cryptodev: redefine ec group enum Arek Kusztal
2022-05-20  5:54 ` [PATCH 02/40] cryptodev: remove list end enumerators Arek Kusztal
2022-05-20  7:19   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 03/40] test/crypto: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 04/40] cryptodev: reduce number of comments in asym xform Arek Kusztal
2022-05-24 10:59   ` [EXT] " Akhil Goyal
2022-05-24 17:37     ` Kusztal, ArkadiuszX
2022-05-25  5:44       ` Akhil Goyal
2022-05-20  5:54 ` [PATCH 05/40] test/crypto: removed asym xform none Arek Kusztal
2022-05-20  5:54 ` [PATCH 06/40] cryptodev: separate key exchange operation enum Arek Kusztal
2022-05-24 11:45   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 07/40] crypto/openssl: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 08/40] test/crypto: " Arek Kusztal
2022-05-20  7:18   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 09/40] cryptodev: remove unnecessary zero assignement Arek Kusztal
2022-05-20  7:13   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 10/40] cryptodev: remove comment about using ephemeral key in dsa Arek Kusztal
2022-05-20  5:54 ` [PATCH 11/40] cryptodev: remove asym crypto next xform Arek Kusztal
2022-05-20  7:22   ` [EXT] " Akhil Goyal
2022-05-24 11:12   ` Akhil Goyal
2022-05-24 14:47     ` Kusztal, ArkadiuszX
2022-05-25  6:06       ` Akhil Goyal
2022-05-25  6:36         ` Kusztal, ArkadiuszX
2022-05-25  7:05           ` Anoob Joseph [this message]
2022-05-27  6:30             ` Kusztal, ArkadiuszX
2022-05-27  6:40               ` Kusztal, ArkadiuszX
2022-05-27  6:55                 ` Kusztal, ArkadiuszX
2022-05-27  7:27                   ` Anoob Joseph
2022-05-27  7:47                     ` Kusztal, ArkadiuszX
2022-05-20  5:54 ` [PATCH 12/40] crypto/openssl: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 13/40] test/crypto: " Arek Kusztal
2022-05-20  7:24   ` [EXT] " Akhil Goyal
2022-05-20  7:38     ` Kusztal, ArkadiuszX
2022-05-20  5:54 ` [PATCH 14/40] app/test-crypto-perf: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 15/40] app/test-eventdev: " Arek Kusztal
2022-05-20  7:25   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 16/40] cryptodev: move dh type from xform to dh op Arek Kusztal
2022-05-24 11:52   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 17/40] crypto/openssl: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 18/40] test/crypto: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 19/40] cryptodev: changed order of dh fields Arek Kusztal
2022-05-20  5:54 ` [PATCH 20/40] cryptodev: add elliptic curve diffie hellman Arek Kusztal
2022-05-24 12:08   ` [EXT] " Akhil Goyal
2022-05-24 14:52     ` Kusztal, ArkadiuszX
2022-05-24 14:55       ` Kusztal, ArkadiuszX
2022-05-25  6:02         ` Akhil Goyal
2022-05-25  6:33           ` Kusztal, ArkadiuszX
2022-05-20  5:54 ` [PATCH 21/40] cryptodev: add public key verify option Arek Kusztal
2022-05-24 12:12   ` [EXT] " Akhil Goyal
2022-05-24 14:59     ` Kusztal, ArkadiuszX
2022-05-25  6:00       ` Akhil Goyal
2022-05-25  6:30         ` Kusztal, ArkadiuszX
2022-05-20  5:54 ` [PATCH 22/40] cryptodev: move RSA padding into separate struct Arek Kusztal
2022-05-20  5:54 ` [PATCH 23/40] crypto/qat: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 24/40] crypto/openssl: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 25/40] crypto/octeontx: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 26/40] crypto/cnxk: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 27/40] common/cpt: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 28/40] test/crypto: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 29/40] cryptodev: add salt length and optional label Arek Kusztal
2022-05-24 12:30   ` [EXT] " Akhil Goyal
2022-05-24 15:14     ` Kusztal, ArkadiuszX
2022-05-25  5:57       ` Akhil Goyal
2022-05-20  5:54 ` [PATCH 30/40] cryptodev: reduce rsa struct to only necessary fields Arek Kusztal
2022-05-24 12:52   ` [EXT] " Akhil Goyal
2022-05-24 15:33     ` Kusztal, ArkadiuszX
2022-05-25  5:48       ` Akhil Goyal
2022-05-20  5:54 ` [PATCH 31/40] crypto/qat: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 32/40] crypto/openssl: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 33/40] crypto/octeontx: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 34/40] crypto/cnxk: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 35/40] common/cpt: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 36/40] test/crypto: " Arek Kusztal
2022-05-20  5:54 ` [PATCH 37/40] cryptodev: add asym op flags Arek Kusztal
2022-05-20 12:07   ` [EXT] " Akhil Goyal
2022-05-20  5:54 ` [PATCH 38/40] cryptodev: clarify usage of private key in dh Arek Kusztal
2022-05-24 12:56   ` [EXT] " Akhil Goyal
2022-05-24 14:30     ` Kusztal, ArkadiuszX
2022-05-25  6:09       ` Akhil Goyal
2022-05-25  6:37         ` Kusztal, ArkadiuszX
2022-05-20  5:54 ` [PATCH 39/40] crypto/openssl: generate dh private key Arek Kusztal
2022-05-20  5:54 ` [PATCH 40/40] test/crypto: added test for dh priv key generation Arek Kusztal
2022-05-20  7:30 ` [EXT] [PATCH 00/40] cryptodev: rsa, dh, ecdh changes Akhil Goyal
2022-05-20  7:37   ` Kusztal, ArkadiuszX

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=PH0PR18MB46728E58279FF867A33A2886DFD69@PH0PR18MB4672.namprd18.prod.outlook.com \
    --to=anoobj@marvell.com \
    --cc=arkadiuszx.kusztal@intel.com \
    --cc=dev@dpdk.org \
    --cc=gakhil@marvell.com \
    --cc=kirankumark@marvell.com \
    --cc=rbalu@marvell.com \
    --cc=roy.fan.zhang@intel.com \
    --cc=ukartha@marvell.com \
    /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).