[v3] examples/ipsec-secgw: set AES-CTR IV length to 16

Message ID 20230223154306.2807523-1-ktejasree@marvell.com (mailing list archive)
State Accepted, archived
Delegated to: akhil goyal
Headers
Series [v3] examples/ipsec-secgw: set AES-CTR IV length to 16 |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/loongarch-compilation success Compilation OK
ci/loongarch-unit-testing success Unit Testing PASS
ci/Intel-compilation success Compilation OK
ci/iol-broadcom-Functional success Functional Testing PASS
ci/intel-Testing success Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-broadcom-Performance fail Performance Testing issues
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/github-robot: build fail github build: failed
ci/iol-testing success Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS

Commit Message

Tejasree Kondoj Feb. 23, 2023, 3:43 p.m. UTC
  Set AES-CTR IV length to 16 which includes
8B per packet IV, 4B nonce and 4B counter
as populated in datapath.

Signed-off-by: Tejasree Kondoj <ktejasree@marvell.com>
---

v3:
* Changed IV length in initialization.
v2:
* Rebased v1

 examples/ipsec-secgw/sa.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
  

Comments

Akhil Goyal Feb. 27, 2023, 5:45 p.m. UTC | #1
> Subject: [PATCH v3] examples/ipsec-secgw: set AES-CTR IV length to 16
> 
> Set AES-CTR IV length to 16 which includes
> 8B per packet IV, 4B nonce and 4B counter
> as populated in datapath.
> 
> Signed-off-by: Tejasree Kondoj <ktejasree@marvell.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>

Applied to dpdk-next-crypto
Thanks.
  

Patch

diff --git a/examples/ipsec-secgw/sa.c b/examples/ipsec-secgw/sa.c
index 7da9444a7b..eb485e6b2b 100644
--- a/examples/ipsec-secgw/sa.c
+++ b/examples/ipsec-secgw/sa.c
@@ -96,7 +96,10 @@  const struct supported_cipher_algo cipher_algos[] = {
 	{
 		.keyword = "aes-128-ctr",
 		.algo = RTE_CRYPTO_CIPHER_AES_CTR,
-		.iv_len = 8,
+		/* iv_len includes 8B per packet IV, 4B nonce
+		 * and 4B counter
+		 */
+		.iv_len = 16,
 		.block_size = 4,
 		.key_len = 20
 	},