diff options
author | Fan Zhang <roy.fan.zhang@intel.com> | 2022-05-25 20:03:40 +0000 |
---|---|---|
committer | Piotr Bronowski <piotrx.bronowski@intel.com> | 2022-06-29 10:34:22 +0000 |
commit | ab0bf0c0cbb66a807e4e8a04462ab56be12c4524 (patch) | |
tree | 254703f02d706e92cb04371f2571ad767bf42772 /test/template_ipsec.py | |
parent | 422544363c5010b4580eb15f3661aa59ad9e4ad9 (diff) |
ipsec: add fast path python tests
This patch introduces set of python tests for fast path, based on
flow cache tests. There was a bug in calculating of policy mask when
adding to fast path, which has been fixed. Memory size for bihash
tables for both ip4 and ip6 outbound fast path policies
has been increased.
Type: feature
Signed-off-by: Piotr Bronowski <piotrx.bronowski@intel.com>
Change-Id: Ibeee904ae7179f5dafbd45bb44282436f0b80821
Diffstat (limited to 'test/template_ipsec.py')
-rw-r--r-- | test/template_ipsec.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/template_ipsec.py b/test/template_ipsec.py index 578c284f72e..1b1c9aaa25d 100644 --- a/test/template_ipsec.py +++ b/test/template_ipsec.py @@ -1888,6 +1888,15 @@ class IPSecIPv4Fwd(VppTestCase): policy_type, remove=False, all_ips=False, + ip_range=False, + local_ip_start=ip_address("0.0.0.0"), + local_ip_stop=ip_address("255.255.255.255"), + remote_ip_start=ip_address("0.0.0.0"), + remote_ip_stop=ip_address("255.255.255.255"), + remote_port_start=0, + remote_port_stop=65535, + local_port_start=0, + local_port_stop=65535, ): spd = VppIpsecSpd(self, spd_id) @@ -1896,6 +1905,13 @@ class IPSecIPv4Fwd(VppTestCase): src_range_high = ip_address("255.255.255.255") dst_range_low = ip_address("0.0.0.0") dst_range_high = ip_address("255.255.255.255") + + elif ip_range: + src_range_low = local_ip_start + src_range_high = local_ip_stop + dst_range_low = remote_ip_start + dst_range_high = remote_ip_stop + else: src_range_low = src_if.remote_ip4 src_range_high = src_if.remote_ip4 @@ -1914,6 +1930,10 @@ class IPSecIPv4Fwd(VppTestCase): priority=priority, policy=self.get_policy(policy_type), is_outbound=is_out, + remote_port_start=remote_port_start, + remote_port_stop=remote_port_stop, + local_port_start=local_port_start, + local_port_stop=local_port_stop, ) if remove is False: |