ipsec: fix SA names consistency in tests 72/37672/6
authorArthur de Kerhor <arthurdekerhor@gmail.com>
Wed, 16 Nov 2022 17:45:24 +0000 (18:45 +0100)
committerNeale Ranns <neale@graphiant.com>
Mon, 6 Feb 2023 03:49:14 +0000 (03:49 +0000)
commit0df06b6e95b6a3261c8e9c261c7a4a661d6ea25a
tree16c4f723367566c965bffda369bb1f56dcf566ce
parentab412cdc07e19a872037e4034caa522398c4be07
ipsec: fix SA names consistency in tests

In some IPsec tests, the SA called scapy_sa designs the SA that
encrypts Scapy packets and decrypts them in VPP, and the one
called vpp_sa the SA that encrypts VPP packets and decrypts them
with Scapy. However, this pattern is not consistent across all
tests. Some tests use the opposite logic. Others even mix both
correlating scapy_tra_spi with vpp_tra_sa_id and vice-versa.

Because of that, sometimes, the SA called vpp_sa_in is used as an
outbound SA and vpp_sa_out as an inbound one.

This patch forces all the tests to follow the same following logic:
- scapy_sa is the SA used to encrypt Scapy packets and decrypt
them in VPP. It matches the VPP inbound SA.
- vpp_sa is the SA used to encrypt VPP packets and decrypt them in
Scapy. It matches the VPP outbound SA.

Type: fix
Signed-off-by: Arthur de Kerhor <arthurdekerhor@gmail.com>
Change-Id: Iadccdccbf98e834add13b5f4ad87af57e2ea3c2a
test/template_ipsec.py
test/test_gso.py
test/test_ipsec_ah.py
test/test_ipsec_esp.py
test/test_ipsec_tun_if_esp.py