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 867B8A034F; Mon, 11 Oct 2021 13:41:33 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id ED10D410E2; Mon, 11 Oct 2021 13:41:27 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 2CC3C4003C for ; Mon, 11 Oct 2021 13:41:25 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10133"; a="207660482" X-IronPort-AV: E=Sophos;i="5.85,364,1624345200"; d="scan'208";a="207660482" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Oct 2021 04:41:24 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.85,364,1624345200"; d="scan'208";a="479821919" Received: from silpixa00400884.ir.intel.com ([10.243.22.82]) by orsmga007.jf.intel.com with ESMTP; 11 Oct 2021 04:41:21 -0700 From: Radu Nicolau To: Ray Kinsella , Akhil Goyal , Declan Doherty Cc: dev@dpdk.org, konstantin.ananyev@intel.com, vladimir.medvedkin@intel.com, bruce.richardson@intel.com, roy.fan.zhang@intel.com, hemant.agrawal@nxp.com, anoobj@marvell.com, abhijit.sinha@intel.com, daniel.m.buckley@intel.com, marchana@marvell.com, ktejasree@marvell.com, matan@nvidia.com, Radu Nicolau Date: Mon, 11 Oct 2021 12:29:36 +0100 Message-Id: <20211011112945.2876-2-radu.nicolau@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211011112945.2876-1-radu.nicolau@intel.com> References: <20210713133542.3550525-1-radu.nicolau@intel.com> <20211011112945.2876-1-radu.nicolau@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v8 01/10] security: add ESN field to ipsec_xform 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 Sender: "dev" Update ipsec_xform definition to include ESN field. This allows the application to control the ESN starting value. Signed-off-by: Declan Doherty Signed-off-by: Radu Nicolau Signed-off-by: Abhijit Sinha Signed-off-by: Daniel Martin Buckley Acked-by: Fan Zhang Acked-by: Anoob Joseph --- doc/guides/rel_notes/deprecation.rst | 2 +- doc/guides/rel_notes/release_21_11.rst | 4 ++++ lib/security/rte_security.h | 8 ++++++++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index baf15aa722..8b7b0beee2 100644 --- a/doc/guides/rel_notes/deprecation.rst +++ b/doc/guides/rel_notes/deprecation.rst @@ -212,7 +212,7 @@ Deprecation Notices * security: The structure ``rte_security_ipsec_xform`` will be extended with multiple fields: source and destination port of UDP encapsulation, - IPsec payload MSS (Maximum Segment Size), and ESN (Extended Sequence Number). + IPsec payload MSS (Maximum Segment Size). * security: The IPsec SA config options ``struct rte_security_ipsec_sa_options`` will be updated with new fields to support new features like IPsec inner diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst index c0a7f75518..401c6d453a 100644 --- a/doc/guides/rel_notes/release_21_11.rst +++ b/doc/guides/rel_notes/release_21_11.rst @@ -229,6 +229,10 @@ ABI Changes ``rte_security_ipsec_xform`` to allow applications to configure SA soft and hard expiry limits. Limits can be either in number of packets or bytes. +* security: A new structure ``esn`` was added in structure + ``rte_security_ipsec_xform`` to set an initial ESN value. This permits + application to start from an arbitrary ESN value for debug and SA lifetime + enforcement purposes. Known Issues ------------ diff --git a/lib/security/rte_security.h b/lib/security/rte_security.h index 2013e65e49..371d64647a 100644 --- a/lib/security/rte_security.h +++ b/lib/security/rte_security.h @@ -280,6 +280,14 @@ struct rte_security_ipsec_xform { /**< Anti replay window size to enable sequence replay attack handling. * replay checking is disabled if the window size is 0. */ + union { + uint64_t value; + struct { + uint32_t low; + uint32_t hi; + }; + } esn; + /**< Extended Sequence Number */ }; /** -- 2.25.1