summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRadu Nicolau <radu.nicolau@intel.com>2018-02-09 10:40:05 +0000
committerThomas Monjalon <thomas@monjalon.net>2018-02-13 23:21:33 +0100
commit63f6da4d0a6c0ffe090543323e49a8726920e860 (patch)
tree4c8ff5d3991da10fbd9f6654c7a93cef451273f6
parentec94968ed4c53d7fa16a49b7243ece10b93ab8ba (diff)
downloaddpdk-draft-windows-63f6da4d0a6c0ffe090543323e49a8726920e860.zip
dpdk-draft-windows-63f6da4d0a6c0ffe090543323e49a8726920e860.tar.gz
dpdk-draft-windows-63f6da4d0a6c0ffe090543323e49a8726920e860.tar.xz
examples/ipsec-secgw: fix printed crypto name
When AES-256 was used aes-128 was printed in the console Fixes: fa9088849e12 ("examples/ipsec-secgw: support AES 256") Signed-off-by: Radu Nicolau <radu.nicolau@intel.com> Acked-by: Anoob Joseph <anoob.joseph@caviumnetworks.com>
-rw-r--r--examples/ipsec-secgw/sa.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/ipsec-secgw/sa.c b/examples/ipsec-secgw/sa.c
index 21239dd..d9dcc0e 100644
--- a/examples/ipsec-secgw/sa.c
+++ b/examples/ipsec-secgw/sa.c
@@ -631,7 +631,8 @@ print_one_sa_rule(const struct ipsec_sa *sa, int inbound)
printf("\tspi_%s(%3u):", inbound?"in":"out", sa->spi);
for (i = 0; i < RTE_DIM(cipher_algos); i++) {
- if (cipher_algos[i].algo == sa->cipher_algo) {
+ if (cipher_algos[i].algo == sa->cipher_algo &&
+ cipher_algos[i].key_len == sa->cipher_key_len) {
printf("%s ", cipher_algos[i].keyword);
break;
}