From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id E9CD7A0548; Wed, 1 Jun 2022 12:11:56 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BE8D542BAC; Wed, 1 Jun 2022 12:11:00 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mails.dpdk.org (Postfix) with ESMTP id 667B242B89 for ; Wed, 1 Jun 2022 12:10:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1654078258; x=1685614258; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=WhBRcdkgW42wUpI4wkVkokmpCDpG5WLA6/QVJJfhQUU=; b=dUk94+ygves9KA/YSIG3nQXDG1UPhThqBMLaWdwKinoOXn6caHrTHvQi L++OZUDrBt+q35IWCzYWaLUuai4/MO+sxfty221wHcx5BUCmfRyycxAVW Y155AxHKMuD3onjReqkJVyfza7sYrPPVI3zuwOlq+ovGoLhr1fXL76wg5 SM27IP1rLon74o1xSFKolOJyM3vA/eJTmaQOYCNKzJsLCJRt4/ncz1ZHW jk0nVyxOttOESdrBjoy/xmC9NZ/pPUkFIb1TUwKA0NoZa5Wu5UNN5Fu/V 70SnCWA6rqvxpWpQ91m6GI+c3lFNi/pxnOy4ZZnIj8cuceiqy/K5R4njU w==; X-IronPort-AV: E=McAfee;i="6400,9594,10364"; a="275616512" X-IronPort-AV: E=Sophos;i="5.91,266,1647327600"; d="scan'208";a="275616512" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Jun 2022 03:10:53 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.91,266,1647327600"; d="scan'208";a="606186087" Received: from silpixa00399302.ir.intel.com ([10.237.214.136]) by orsmga008.jf.intel.com with ESMTP; 01 Jun 2022 03:10:51 -0700 From: Arek Kusztal To: dev@dpdk.org Cc: gakhil@marvell.com, roy.fan.zhang@intel.com, Arek Kusztal Subject: [PATCH v5 11/12] cryptodev: clarify rsa verify with none padding Date: Wed, 1 Jun 2022 10:02:48 +0100 Message-Id: <20220601090249.86865-12-arkadiuszx.kusztal@intel.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20220601090249.86865-1-arkadiuszx.kusztal@intel.com> References: <20220601090249.86865-1-arkadiuszx.kusztal@intel.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org - Clarified where should output be stored of signature decryption with padding none. PMD is not able to know what padding algorithm was used, therefore decrypted signature should be returned to the user. - Removed incorrect big-endian constraints. Not all data in RSA can be treated as big endian integer, therefore some of the constraints were lifted. Signed-off-by: Arek Kusztal --- lib/cryptodev/rte_crypto_asym.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/lib/cryptodev/rte_crypto_asym.h b/lib/cryptodev/rte_crypto_asym.h index ae0b62c22f..aaa4bf9952 100644 --- a/lib/cryptodev/rte_crypto_asym.h +++ b/lib/cryptodev/rte_crypto_asym.h @@ -398,8 +398,6 @@ struct rte_crypto_rsa_op_param { * (i.e. must be at least RSA key size). The message.length * field should be 0 and will be overwritten by the PMD * with the decrypted length. - * - * All data is in Octet-string network byte order format. */ rte_crypto_param cipher; @@ -414,7 +412,8 @@ struct rte_crypto_rsa_op_param { * at least RSA key size). The cipher.length field should * be 0 and will be overwritten by the PMD with the encrypted length. * - * All data is in Octet-string network byte order format. + * When RTE_CRYPTO_RSA_PADDING_NONE and RTE_CRYPTO_ASYM_OP_VERIFY + * selected, this is an output of decrypted signature. */ rte_crypto_param sign; @@ -428,8 +427,6 @@ struct rte_crypto_rsa_op_param { * with enough memory to hold signature output (i.e. must be * at least RSA key size). The sign.length field should * be 0 and will be overwritten by the PMD with the signature length. - * - * All data is in Octet-string network byte order format. */ struct rte_crypto_rsa_padding padding; -- 2.13.6