From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM04-SN1-obe.outbound.protection.outlook.com (mail-eopbgr700071.outbound.protection.outlook.com [40.107.70.71]) by dpdk.org (Postfix) with ESMTP id 7CE8A1BF16 for ; Tue, 3 Jul 2018 16:59:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=imSmZjBccJnYykIXnuU0kdZUMhuqiHNPBkLEugUSGv8=; b=NqYvHft8WW1f2DvlcknuA1lJLilwJ2PDrpfobRwTnQg4I1nMU8gCmp3DZEJbmByGuRI4vSSl3TDRqWBIpmwqEHwngQgiN7lWFp8tRdIHoEjR52XiTnqdlIfX44grHiQaFc4ONXqe4YWXlbQd0u94VEJqVJZlhLpst5z34nm/0YE= Received: from CY4PR0701MB3634.namprd07.prod.outlook.com (52.132.101.164) by CY4PR0701MB3825.namprd07.prod.outlook.com (52.132.102.159) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.906.26; Tue, 3 Jul 2018 14:59:37 +0000 Received: from CY4PR0701MB3634.namprd07.prod.outlook.com ([fe80::f55a:7354:8d2f:cf0b]) by CY4PR0701MB3634.namprd07.prod.outlook.com ([fe80::f55a:7354:8d2f:cf0b%4]) with mapi id 15.20.0906.026; Tue, 3 Jul 2018 14:59:37 +0000 From: "Verma, Shally" To: "Trahe, Fiona" , "De Lara Guarch, Pablo" CC: "akhil.goyal@nxp.com" , "dev@dpdk.org" , "Athreya, Narayana Prasad" , "Sahu, Sunila" , "Gupta, Ashish" Thread-Topic: [PATCH v3 5/6] crypto/openssl: add asym crypto support Thread-Index: AQHUEt07KGZjFssjA0CuR01IyHXkk6R9lgJA Date: Tue, 3 Jul 2018 14:59:37 +0000 Message-ID: References: <1526450713-17299-1-git-send-email-shally.verma@caviumnetworks.com> <1526450713-17299-6-git-send-email-shally.verma@caviumnetworks.com> <348A99DA5F5B7549AA880327E580B435895BAC50@IRSMSX101.ger.corp.intel.com> In-Reply-To: <348A99DA5F5B7549AA880327E580B435895BAC50@IRSMSX101.ger.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Shally.Verma@cavium.com; x-originating-ip: [115.113.156.2] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; CY4PR0701MB3825; 7:hLmjb+Dknmk6oSsfE8v3xdltesb4pqWwevEuZgkQUag/Gdp5kgJy4cLyQ93OhXf4LdnqxdG+T9rxHarFrrMfFUIKHtMGq/z2MA+kWjSM1laOpzjIhzu0zDeXcyLj2A9nyketjanj3Zz/f/S6gAnFQKaPpkG9194Pkp9MDgCH7pobflQQJo4QjvC0bntxTd8uv+00SxpouaRzl5fcWUuu/Yn5ouv/yrwZ5wvm/NtZFdr/MWK0FQKmgjma7tzEWRT+ x-ms-exchange-antispam-srfa-diagnostics: SOS;SOR; x-forefront-antispam-report: SFV:SKI; SCL:-1; SFV:NSPM; SFS:(10009020)(346002)(396003)(376002)(39850400004)(136003)(366004)(13464003)(189003)(199004)(256004)(2900100001)(14444005)(9686003)(102836004)(26005)(99286004)(55016002)(33656002)(5250100002)(25786009)(97736004)(8936002)(8676002)(6436002)(229853002)(186003)(5660300001)(81156014)(110136005)(81166006)(54906003)(316002)(76176011)(478600001)(72206003)(7696005)(68736007)(53546011)(4326008)(6506007)(6246003)(446003)(74316002)(11346002)(305945005)(105586002)(86362001)(66066001)(6116002)(2906002)(3846002)(486006)(106356001)(53936002)(14454004)(107886003)(476003)(7736002); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR0701MB3825; H:CY4PR0701MB3634.namprd07.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; x-ms-office365-filtering-correlation-id: 91b641f9-feda-47af-4635-08d5e0f59890 x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989117)(5600053)(711020)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060)(7193020); SRVR:CY4PR0701MB3825; x-ms-traffictypediagnostic: CY4PR0701MB3825: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(185117386973197)(228905959029699); x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3002001)(3231254)(944501410)(52105095)(10201501046)(93006095)(93001095)(149027)(150027)(6041310)(20161123560045)(20161123564045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(6072148)(201708071742011)(7699016); SRVR:CY4PR0701MB3825; BCL:0; PCL:0; RULEID:; SRVR:CY4PR0701MB3825; x-forefront-prvs: 0722981D2A received-spf: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: GmuKS/2qB4KgXJ5/vyYiv7SjnVKRhCgVPkpnYSH8F1wBMz4jFBMNY11AtskQkg8tRTOWXnf8A3l3m73MImtRx037wHvIMvMCokzTXOxtCeepY/wZqRBDY97lnZ2G37/kD24pbM93ZKZvDrTraZI9fqfBmuBYEcoHp8rSsHQM9n85lxGJxzWrhXJQxcBlLDK78DsCQdsGf4VwdM0+gnYK3tzqOt9S3Ty1S2nF/vYjX402Iwh8MwCBC583feaUM1Irl1vpU2m1tM+vOHhHUty6VgdTXpinLRhGEjURKsoie1rnMUGkunbnx0xsZwCisHh0Mty1zpD9grpTppeXBETw2JgAmox9jNYlFzZo51QlCds= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-Network-Message-Id: 91b641f9-feda-47af-4635-08d5e0f59890 X-MS-Exchange-CrossTenant-originalarrivaltime: 03 Jul 2018 14:59:37.3153 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR0701MB3825 Subject: Re: [dpdk-dev] [PATCH v3 5/6] crypto/openssl: add asym crypto support X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Jul 2018 14:59:41 -0000 >-----Original Message----- >From: Trahe, Fiona [mailto:fiona.trahe@intel.com] >Sent: 03 July 2018 20:21 >To: Verma, Shally ; De Lara Guarch, Pablo >Cc: akhil.goyal@nxp.com; dev@dpdk.org; Athreya, Narayana Prasad ; Sahu, Sunila >; Gupta, Ashish ; Trahe, = Fiona >Subject: RE: [PATCH v3 5/6] crypto/openssl: add asym crypto support > >External Email > >Hi Shally, > >> -----Original Message----- >> From: Shally Verma [mailto:shally.verma@caviumnetworks.com] >> Sent: Wednesday, May 16, 2018 7:05 AM >> To: De Lara Guarch, Pablo >> Cc: Trahe, Fiona ; akhil.goyal@nxp.com; dev@dpdk.= org; >> pathreya@caviumnetworks.com; Sunila Sahu ; Ashish Gupta >> >> Subject: [PATCH v3 5/6] crypto/openssl: add asym crypto support >> >> Add asymmetric crypto operation support in openssl PMD. >> Current list of supported asym xforms: >> * RSA >> * DSA >> * Deffie-hellman >> * Modular Operations >> >> changes from v2: >> - Update the pmd capability as per new capability structure >> >> changes from v1: >> - resolve new line error in dod/guides/cryptodevs/openssl.rst >> >> Signed-off-by: Shally Verma >> Signed-off-by: Sunila Sahu >> Signed-off-by: Ashish Gupta > > >//snip// >> +/* process rsa operations */ >> +static int process_openssl_rsa_op(struct rte_crypto_op *cop, >> + struct openssl_asym_session *sess) >> +{ >> + int ret =3D 0; >> + struct rte_crypto_asym_op *op =3D cop->asym; >> + RSA *rsa =3D sess->u.r.rsa; >> + uint32_t pad =3D (op->rsa.pad); >> + >> + switch (pad) { >> + case RTE_CRYPTO_RSA_PKCS1_V1_5_BT1: >> + case RTE_CRYPTO_RSA_PKCS1_V1_5_BT2: >> + pad =3D RSA_PKCS1_PADDING; >> + break; >> + case RTE_CRYPTO_RSA_PADDING_PSS: >> + pad =3D RSA_PKCS1_PSS_PADDING; >> + /* fall through */ >> + case RTE_CRYPTO_RSA_PADDING_OAEP: >> + pad =3D RSA_PKCS1_OAEP_PADDING; >> + /* fall through */ >> + default: >> + pad =3D RSA_NO_PADDING; >> + break; >[Fiona] Maybe I'm missing something, but won't this fall through to RSA_NO= _PADDING for OAEP and PSS cases? > >//snip// Yes. It will because we were not claiming OAEP/PSS support in 1st cut. Also= , So, made them switched to no-padding.=20 However, openssl PMD asym changes , as such, is on hold until it is moved t= hat to 1.1.0. So, we will submit PMD and testapp as a separate patches fro= m=20 Lib patch series.