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 931FBA0A0E; Thu, 4 Feb 2021 09:19:27 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 58BFB2405BE; Thu, 4 Feb 2021 09:19:27 +0100 (CET) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mails.dpdk.org (Postfix) with ESMTP id 6427A24059F for ; Thu, 4 Feb 2021 09:19:24 +0100 (CET) IronPort-SDR: /h64pbDx+AJCEMy9aUBZawarkDAbNF36EiLgGBzWUJiiP3JPHCiR86rYfmKOv1fVpELMuP2mcq LocVYKOnPEQA== X-IronPort-AV: E=McAfee;i="6000,8403,9884"; a="200180462" X-IronPort-AV: E=Sophos;i="5.79,400,1602572400"; d="scan'208";a="200180462" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Feb 2021 00:19:23 -0800 IronPort-SDR: dBLP+A4EWY9ppwk2jSflDlPEnfV5sfOfXsxLWMJ9NLc3vloBxwyUOqU0mZqDnbdeFUbvNNdEtl +5jQCN2YwFuA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.79,400,1602572400"; d="scan'208";a="372323745" Received: from pengyuan-dpdk.sh.intel.com ([10.67.117.236]) by fmsmga008.fm.intel.com with ESMTP; 04 Feb 2021 00:19:20 -0800 From: Peng Yuan To: dts@dpdk.org Cc: Peng Yuan Date: Thu, 4 Feb 2021 01:18:41 +0000 Message-Id: <20210204011841.19306-1-yuan.peng@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [dts] [PATCH v1]tests: add gtpogre packet check to TestSuite_cvl_advanced_iavf_rss_gtpu.py X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" GTPoGRE is imported in DPDK-21.02. The Ptype is parsed same as GTP packet, so they match gtp RSS rule. Add GTPoGRE packets check to TestSuite_cvl_advanced_iavf_rss_gtpu.py Signed-off-by: Peng Yuan diff --git a/tests/TestSuite_cvl_advanced_iavf_rss_gtpu.py b/tests/TestSuite_cvl_advanced_iavf_rss_gtpu.py index c94a15d2..7b7dc2bc 100755 --- a/tests/TestSuite_cvl_advanced_iavf_rss_gtpu.py +++ b/tests/TestSuite_cvl_advanced_iavf_rss_gtpu.py @@ -44,6 +44,7 @@ mac_ipv4_gtpu_ipv4_basic = { 'ipv4-icmp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1", src="192.168.0.2")/ICMP()/("X"*480)', 'ipv4-tcp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1", src="192.168.0.2")/TCP()/("X"*480)', 'ipv4-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP()/("X"*480)', + 'gtpogre-ipv4-nonfrag': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/("X"*480)', } mac_ipv4_gtpu_ipv4_l3src_changed_pkt = eval(str(mac_ipv4_gtpu_ipv4_basic).replace('192.168.0.2', '192.168.1.2')) @@ -66,6 +67,18 @@ mac_ipv4_gtpu_ipv4_l3dst_only = { 'send_packet': mac_ipv4_gtpu_ipv4_l3src_changed_pkt['ipv4-nonfrag'], 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_l3dst_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_l3src_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_ipv4_basic['ipv4-frag'], 'action': 'save_hash', @@ -123,6 +136,7 @@ mac_ipv4_gtpu_ipv4_l3dst_only = { mac_ipv4_gtpu_ipv4_basic['ipv4-icmp'], mac_ipv4_gtpu_ipv4_basic['ipv4-tcp'], mac_ipv4_gtpu_ipv4_basic['ipv4-udp'], + mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -156,6 +170,22 @@ mac_ipv4_gtpu_ipv4_all = { 'send_packet': mac_ipv4_gtpu_ipv4_basic['ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), 'action': 'check_hash_different', }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_l3dst_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_l3src_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), + 'action': 'check_hash_different', + }, { 'send_packet': mac_ipv4_gtpu_ipv4_basic['ipv4-frag'], 'action': 'save_hash', @@ -229,6 +259,7 @@ mac_ipv4_gtpu_ipv4_all = { mac_ipv4_gtpu_ipv4_basic['ipv4-icmp'], mac_ipv4_gtpu_ipv4_basic['ipv4-tcp'], mac_ipv4_gtpu_ipv4_basic['ipv4-udp'], + mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -252,6 +283,18 @@ mac_ipv4_gtpu_ipv4_gtpu = { 'send_packet': mac_ipv4_gtpu_ipv4_basic['ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'].replace('teid=0x123456', 'teid=0x12345'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_ipv4_basic['ipv4-frag'], 'action': 'save_hash', @@ -297,6 +340,7 @@ mac_ipv4_gtpu_ipv4_gtpu = { mac_ipv4_gtpu_ipv4_basic['ipv4-icmp'], mac_ipv4_gtpu_ipv4_basic['ipv4-tcp'], mac_ipv4_gtpu_ipv4_basic['ipv4-udp'], + mac_ipv4_gtpu_ipv4_basic['gtpogre-ipv4-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -327,6 +371,14 @@ mac_ipv4_gtpu_ipv4_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.2",src="192.168.0.1", frag=6)/("X"*480)', 'action': 'check_hash_same', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2", frag=6)/("X"*480)', + 'action': {'save_hash': 'ipv4-frag'}, + }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.2",src="192.168.0.1", frag=6)/("X"*480)', + 'action': 'check_hash_same', + }, { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/ICMP()/("X"*480)', 'action': {'save_hash': 'ipv4-icmp'}, @@ -353,6 +405,10 @@ mac_ipv4_gtpu_ipv4_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(src="192.168.0.3",dst="192.168.0.8",frag=6)/("X"*480)', 'action': {'check_no_hash_or_different': 'ipv4-frag'}, }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(src="192.168.0.3",dst="192.168.0.8",frag=6)/("X"*480)', + 'action': {'check_no_hash_or_different': 'ipv4-frag'}, + }, { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(src="192.168.0.10",dst="192.168.0.20")/ICMP()/("X"*480)', 'action': {'check_no_hash_or_different': 'ipv4-icmp'}, @@ -394,6 +450,10 @@ mac_ipv4_gtpu_ipv4_udp_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP(sport=23, dport=22)/("X"*480)', 'action': 'check_hash_same', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=23, dport=22)/("X"*480)', + 'action': 'check_hash_same', + }, ], 'post-test': [ { @@ -408,6 +468,10 @@ mac_ipv4_gtpu_ipv4_udp_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP(sport=23, dport=22)/("X"*480)', 'action': 'check_no_hash_or_different', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=23, dport=22)/("X"*480)', + 'action': 'check_no_hash_or_different', + }, ], } @@ -469,6 +533,14 @@ mac_ipv4_gtpu_eh_dl_ipv4_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP()/("X"*480)', 'action': 'check_hash_same', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP()/("X"*480)', + 'action': {'save_hash': 'ipv4-udp'}, + }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP()/("X"*480)', + 'action': 'check_hash_same', + }, ], 'post-test': [ { @@ -487,6 +559,10 @@ mac_ipv4_gtpu_eh_dl_ipv4_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=1, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP()/("X"*480)', 'action': {'check_no_hash_or_different': 'ipv4-udp'}, }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=1, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP()/("X"*480)', + 'action': {'check_no_hash_or_different': 'ipv4-udp'}, + }, ], } mac_ipv4_gtpu_eh_ul_ipv4_symmetric = eval(str(mac_ipv4_gtpu_eh_dl_ipv4_symmetric) @@ -520,6 +596,10 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP(sport=23, dport=22)/("X"*480)', 'action': 'check_hash_same', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP(sport=22, dport=23)/("X"*480)', + 'action': 'check_hash_same', + }, ], 'post-test': [ { @@ -534,6 +614,10 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_symmetric = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP(sport=23, dport=22)/("X"*480)', 'action': 'check_no_hash_or_different', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.2",src="192.168.0.1")/UDP(sport=22, dport=23)/("X"*480)', + 'action': 'check_no_hash_or_different', + }, ], } mac_ipv4_gtpu_eh_ul_ipv4_udp_symmetric = eval(str(mac_ipv4_gtpu_eh_dl_ipv4_udp_symmetric) @@ -578,7 +662,10 @@ mac_ipv4_gtpu_eh_ipv6_tcp_symmetric = eval(str(mac_ipv4_gtpu_eh_ipv4_tcp_symmetr .replace('ipv4_tcp_symmetric', 'ipv6_tcp_symmetric') ) -mac_ipv4_gtpu_ipv4_udp_basic = 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)' +mac_ipv4_gtpu_ipv4_udp_basic = { + 'ipv4-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', + 'gtpogre-ipv4-udp': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', +} mac_ipv4_gtpu_ipv4_udp_l3dst = { 'sub_casename': 'mac_ipv4_gtpu_ipv4_udp_l3dst', @@ -586,21 +673,37 @@ mac_ipv4_gtpu_ipv4_udp_l3dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l3-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -619,26 +722,47 @@ mac_ipv4_gtpu_ipv4_udp_l3src_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l3-src-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.1', + '192.168.1.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=33').replace('192.168.0.1', + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -650,25 +774,45 @@ mac_ipv4_gtpu_ipv4_udp_l3src_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l3-src-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32').replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=32').replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32').replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -680,25 +824,45 @@ mac_ipv4_gtpu_ipv4_udp_l3dst_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l3-dst-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=33').replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -710,25 +874,45 @@ mac_ipv4_gtpu_ipv4_udp_l3dst_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l3-dst-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32').replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=32').replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32').replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_different', }, ] @@ -739,22 +923,39 @@ mac_ipv4_gtpu_ipv4_udp_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32') + .replace('192.168.0', '192.168.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=32') + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32') .replace('192.168.0', '192.168.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -765,22 +966,39 @@ mac_ipv4_gtpu_ipv4_udp_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=32') + .replace('192.168.0', '192.168.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=32') + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=32') .replace('192.168.0', '192.168.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -792,33 +1010,61 @@ mac_ipv4_gtpu_ipv4_udp_all = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4-udp end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('teid=0x123456', 'teid=0x12345'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('teid=0x123456', 'teid=0x12345'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('teid=0x123456', 'teid=0x12345'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -830,25 +1076,45 @@ mac_ipv4_gtpu_ipv4_udp_l3 = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv4 / udp / end actions rss types ipv4 end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'].replace('sport=22,dport=23', 'sport=12,dport=13'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic.replace('sport=22,dport=23', 'sport=12,dport=13'), + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22,dport=23', 'sport=12,dport=13'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -871,6 +1137,7 @@ mac_ipv4_gtpu_ipv6_basic = { 'ipv6-icmp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/ICMP()/("X"*480)', 'ipv6-tcp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(''src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP()/("X"*480)', 'ipv6-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP()/("X"*480)', + 'gtpogre-ipv6-nonfrag': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/("X"*480)', } mac_ipv4_gtpu_ipv6_l3src_changed_pkt = eval(str(mac_ipv4_gtpu_ipv6_basic).replace('ABAB', '1212')) @@ -893,6 +1160,18 @@ mac_ipv4_gtpu_ipv6_l3dst_only = { 'send_packet': mac_ipv4_gtpu_ipv6_l3src_changed_pkt['ipv6-nonfrag'], 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], + 'action': {'save_hash', 'ipv6-nonfrag'}, + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_l3dst_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_l3src_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_ipv6_basic['ipv6-frag'], 'action': {'save_hash', 'ipv6-frag'}, @@ -950,6 +1229,7 @@ mac_ipv4_gtpu_ipv6_l3dst_only = { mac_ipv4_gtpu_ipv6_basic['ipv6-icmp'], mac_ipv4_gtpu_ipv6_basic['ipv6-tcp'], mac_ipv4_gtpu_ipv6_basic['ipv6-udp'], + mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -973,6 +1253,18 @@ mac_ipv4_gtpu_ipv6_l3src_only = { 'send_packet': mac_ipv4_gtpu_ipv6_l3dst_changed_pkt['ipv6-nonfrag'], 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], + 'action': {'save_hash', 'ipv6-nonfrag'}, + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_l3src_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_l3dst_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_ipv6_basic['ipv6-frag'], 'action': {'save_hash', 'ipv6-frag'}, @@ -1030,6 +1322,7 @@ mac_ipv4_gtpu_ipv6_l3src_only = { mac_ipv4_gtpu_ipv6_basic['ipv6-icmp'], mac_ipv4_gtpu_ipv6_basic['ipv6-tcp'], mac_ipv4_gtpu_ipv6_basic['ipv6-udp'], + mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -1063,6 +1356,22 @@ mac_ipv4_gtpu_ipv6_all = { 'send_packet': mac_ipv4_gtpu_ipv6_basic['ipv6-nonfrag'].replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_different', }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], + 'action': {'save_hash', 'ipv6-nonfrag'}, + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_l3dst_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_l3src_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'].replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, { 'send_packet': mac_ipv4_gtpu_ipv6_basic['ipv6-frag'], 'action': {'save_hash', 'ipv6-frag'}, @@ -1136,6 +1445,7 @@ mac_ipv4_gtpu_ipv6_all = { mac_ipv4_gtpu_ipv6_basic['ipv6-icmp'], mac_ipv4_gtpu_ipv6_basic['ipv6-tcp'], mac_ipv4_gtpu_ipv6_basic['ipv6-udp'], + mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -1159,6 +1469,18 @@ mac_ipv4_gtpu_ipv6_gtpu = { 'send_packet': mac_ipv4_gtpu_ipv6_basic['ipv6-nonfrag'].replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'].replace('teid=0x123456', 'teid=0x12345'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'].replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_ipv6_basic['ipv6-frag'], 'action': 'save_hash', @@ -1204,6 +1526,7 @@ mac_ipv4_gtpu_ipv6_gtpu = { mac_ipv4_gtpu_ipv6_basic['ipv6-icmp'], mac_ipv4_gtpu_ipv6_basic['ipv6-tcp'], mac_ipv4_gtpu_ipv6_basic['ipv6-udp'], + mac_ipv4_gtpu_ipv6_basic['gtpogre-ipv6-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -1213,29 +1536,47 @@ mac_ipv4_gtpu_ipv6_gtpu = { mac_ipv4_gtpu_ipv6_toeplitz = [mac_ipv4_gtpu_ipv6_l3dst_only, mac_ipv4_gtpu_ipv6_l3src_only, mac_ipv4_gtpu_ipv6_all, mac_ipv4_gtpu_ipv6_gtpu] -mac_ipv4_gtpu_ipv6_udp_basic = 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)' - +mac_ipv4_gtpu_ipv6_udp_basic = { + 'ipv6-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)', + 'gtpogre-ipv6-udp': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)', +} mac_ipv4_gtpu_ipv6_udp_l3dst = { 'sub_casename': 'mac_ipv4_gtpu_ipv6_udp_l3dst', 'port_id': 0, 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l3-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -1254,55 +1595,95 @@ mac_ipv4_gtpu_ipv6_udp_l3src_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l3-src-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=33').replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33').replace('CDCD', '3434'), 'action': 'check_hash_same', }, - ], - 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, - 'action': 'check_no_hash_or_different', + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], + 'action': 'save_hash', }, - ] -} - -mac_ipv4_gtpu_ipv6_udp_l3src_l4dst = { + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + ], + 'post-test': [ + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + ] +} + +mac_ipv4_gtpu_ipv6_udp_l3src_l4dst = { 'sub_casename': 'mac_ipv4_gtpu_ipv6_udp_l3src_l4dst', 'port_id': 0, 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l3-src-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=32').replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_different', }, ] @@ -1314,25 +1695,45 @@ mac_ipv4_gtpu_ipv6_udp_l3dst_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l3-dst-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33').replace('ABAB', '1212'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=33').replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33').replace('ABAB', '1212'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -1344,25 +1745,45 @@ mac_ipv4_gtpu_ipv6_udp_l3dst_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l3-dst-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32').replace('ABAB', '1212'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=32').replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32').replace('ABAB', '1212'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -1373,22 +1794,39 @@ mac_ipv4_gtpu_ipv6_udp_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32') + .replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=32') + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32') .replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -1399,22 +1837,39 @@ mac_ipv4_gtpu_ipv6_udp_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=32') + .replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=32') + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=32') .replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -1426,33 +1881,61 @@ mac_ipv4_gtpu_ipv6_udp_all = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / ipv6 / udp / end actions rss types ipv6-udp end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'].replace('teid=0x123456', 'teid=0x12345'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic.replace('teid=0x123456', 'teid=0x12345'), + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('teid=0x123456', 'teid=0x12345'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -1687,7 +2170,7 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic = { 'ipv4-frag': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2", frag=6)/("X"*480)', 'ipv4-icmp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=1, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/ICMP()/("X"*480)', 'ipv4-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP()/("X"*480)', - + 'gtpogre-ipv4-nonfrag': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/("X"*480)', } mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3src_changed_pkt = eval(str(mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic).replace('192.168.0.2', '192.168.1.2')) @@ -1710,6 +2193,18 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3dst_only = { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3src_changed_pkt['ipv4-nonfrag'].replace('0x123456', '0x12345'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3dst_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3src_changed_pkt['gtpogre-ipv4-nonfrag'].replace('0x123456', '0x12345'), + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-nonfrag_ul'], 'action': 'save_hash', @@ -1767,6 +2262,7 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3dst_only = { mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-frag'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-icmp'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-udp'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -1797,6 +2293,18 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_all = { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3src_changed_pkt['ipv4-nonfrag'], 'action': 'check_hash_different', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3dst_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_l3src_changed_pkt['gtpogre-ipv4-nonfrag'], + 'action': 'check_hash_different', + }, { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), 'action': 'check_hash_different', @@ -1894,6 +2402,7 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_all = { mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-frag'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-icmp'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-udp'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -1917,6 +2426,18 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_gtpu = { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'].replace('0x123456', '0x12345'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'].replace('192.168.0.', '192.168.1.'), + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-nonfrag_ul'], 'action': 'save_hash', @@ -1974,6 +2495,7 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_gtpu = { mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-frag'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-icmp'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['ipv4-udp'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_basic['gtpogre-ipv4-nonfrag'], ], 'action': 'check_no_hash', }, @@ -1987,6 +2509,8 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_toeplitz = [mac_ipv4_gtpu_eh_without_ul_dl_i mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic = { 'dl': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22, dport=23)/("X"*480)', 'ul': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=1, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22, dport=23)/("X"*480)', + 'gtpogre-dl': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22, dport=23)/("X"*480)', + 'gtpogre-ul': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=1, P=1, QFI=0x34)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22, dport=23)/("X"*480)', } mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_l3dst_only = { @@ -2022,12 +2546,42 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_l3dst_only = { 'sport=32, dport=33'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.2', '192.168.1.2') + .replace('sport=22, dport=23', + 'sport=32, dport=33'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('192.168.0.2', '192.168.1.2') + .replace('sport=22, dport=23', + 'sport=32, dport=33'), + 'action': 'check_hash_same', + }, ], 'post-test': [ { 'send_packet': [ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['dl'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['ul'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], ], 'action': 'check_no_hash_or_different', }, @@ -2069,12 +2623,38 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_l3src_l4src = { .replace('0x123456', '0x12345'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.1', '192.168.1.1') + .replace('dport=23', 'dport=33') + .replace('0x123456', '0x12345'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('192.168.0.1', '192.168.1.1') + .replace('dport=23', 'dport=33') + .replace('0x123456', '0x12345'), + 'action': 'check_hash_same', + }, ], 'post-test': [ { 'send_packet': [ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['dl'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['ul'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], ], 'action': 'check_no_hash_or_different', }, @@ -2125,12 +2705,34 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_l4src_only = { .replace('0x123456', '0x12345'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0', '192.168.1') + .replace('dport=23', 'dport=33') + .replace('0x123456', '0x12345'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('192.168.0', '192.168.1') + .replace('dport=23', 'dport=33') + .replace('0x123456', '0x12345'), + 'action': 'check_hash_same', + }, ], 'post-test': [ { 'send_packet': [ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['dl'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['ul'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], ], 'action': 'check_no_hash_or_different', }, @@ -2172,12 +2774,38 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp = { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['dl'].replace('0x123456', '0x12345'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('0x123456', '0x12345'), + 'action': 'check_hash_same', + }, ], 'post-test': [ { 'send_packet': [ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['dl'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['ul'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], ], 'action': 'check_no_hash_or_different', }, @@ -2221,12 +2849,46 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_l3 = { 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['ul'].replace('sport=22, dport=23', 'sport=12, dport=13'), 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'].replace('sport=22, dport=23', 'sport=12, dport=13'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'].replace('sport=22, dport=23', 'sport=12, dport=13'), + 'action': 'check_hash_same', + }, ], 'post-test': [ { 'send_packet': [ mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['dl'], mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['ul'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-dl'], + mac_ipv4_gtpu_eh_without_ul_dl_ipv4_udp_basic['gtpogre-ul'], ], 'action': 'check_no_hash_or_different', }, @@ -2284,28 +2946,47 @@ mac_ipv4_gtpu_eh_without_ul_dl_ipv6_tcp_toeplitz = [eval(str(element).replace('g .replace('IP(dst="192.168.1.1",src="192.168.1.2"', 'IPv6(dst="1212:910B:6666:3457:8295:3333:1800:2929",src="3434:910A:2222:5498:8475:1111:3900:2020"')) for element in mac_ipv4_gtpu_eh_without_ul_dl_ipv4_tcp_toeplitz] -mac_ipv4_gtpu_eh_dl_ipv4_udp_basic = 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)' +mac_ipv4_gtpu_eh_dl_ipv4_udp_basic = { + 'ipv4-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', + 'gtpogre-ipv4-udp': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IP(dst="192.168.0.1", src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', +} mac_ipv4_gtpu_eh_dl_ipv4_udp_l3dst = { 'sub_casename': 'mac_ipv4_gtpu_eh_dl_ipv4_udp_l3dst', 'port_id': 0, 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l3-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2325,26 +3006,46 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l3src_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l3-src-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=33').replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_same', }, - ], - 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, - 'action': 'check_no_hash_or_different', + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_same', + }, + ], + 'post-test': [ + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], + 'action': 'check_no_hash_or_different', }, ] } @@ -2355,25 +3056,45 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l3src_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l3-src-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=32').replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32').replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32').replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2385,25 +3106,45 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l3dst_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l3-dst-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=33').replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33').replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2415,26 +3156,47 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l3dst_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l3-dst-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32') + .replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=32') + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32') .replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2445,22 +3207,39 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=32') + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32') + .replace('192.168.0', '192.168.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32') .replace('192.168.0', '192.168.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2471,22 +3250,39 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=32') + .replace('192.168.0', '192.168.1'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=32') + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=32') .replace('192.168.0', '192.168.1'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2498,29 +3294,53 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_all = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4-udp end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2532,25 +3352,45 @@ mac_ipv4_gtpu_eh_dl_ipv4_udp_l3 = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv4 / udp / end actions rss types ipv4 end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.1', '192.168.1.1'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('192.168.0.2', '192.168.1.2'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic.replace('sport=22', 'sport=12').replace('dport=23', 'dport=13'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'].replace('sport=22', 'sport=12').replace('dport=23', 'dport=13'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.1', '192.168.1.1'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('192.168.0.2', '192.168.1.2'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'].replace('sport=22', 'sport=12').replace('dport=23', 'dport=13'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['ipv4-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv4_udp_basic['gtpogre-ipv4-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2583,6 +3423,7 @@ mac_ipv4_gtpu_eh_dl_ipv6_basic = { 'ipv6-icmp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/ICMP()/("X"*480)', 'ipv6-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP()/("X"*480)', 'ipv6-tcp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP()/("X"*480)', + 'gtpogre-ipv6-nonfrag': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/("X"*480)', } mac_ipv4_gtpu_eh_dl_ipv6_l3src_changed_pkt = eval(str(mac_ipv4_gtpu_eh_dl_ipv6_basic).replace('ABAB', '1212')) @@ -2605,6 +3446,18 @@ mac_ipv4_gtpu_eh_dl_ipv6_l3dst_only = { 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_l3src_changed_pkt['ipv6-nonfrag'], 'action': 'check_hash_same', }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_basic['gtpogre-ipv6-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_l3dst_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_l3src_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_same', + }, { 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-frag'], 'action': 'save_hash', @@ -2662,6 +3515,7 @@ mac_ipv4_gtpu_eh_dl_ipv6_l3dst_only = { mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-icmp'], mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-udp'], mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-tcp'], + mac_ipv4_gtpu_eh_dl_ipv6_basic['gtpogre-ipv6-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -2695,6 +3549,22 @@ mac_ipv4_gtpu_eh_dl_ipv6_all = { 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-nonfrag'].replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_different', }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_basic['gtpogre-ipv6-nonfrag'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_l3dst_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_l3src_changed_pkt['gtpogre-ipv6-nonfrag'], + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_basic['gtpogre-ipv6-nonfrag'].replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, { 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-frag'], 'action': 'save_hash', @@ -2768,6 +3638,7 @@ mac_ipv4_gtpu_eh_dl_ipv6_all = { mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-icmp'], mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-udp'], mac_ipv4_gtpu_eh_dl_ipv6_basic['ipv6-tcp'], + mac_ipv4_gtpu_eh_dl_ipv6_basic['gtpogre-ipv6-nonfrag'], ], 'action': 'check_no_hash_or_different', }, @@ -2785,28 +3656,47 @@ mac_ipv4_gtpu_eh_ul_ipv6_toeplitz = [eval(str(element).replace('(type=1', '(type mac_ipv4_gtpu_eh_ipv6_toeplitz = mac_ipv4_gtpu_eh_dl_ipv6_toeplitz + mac_ipv4_gtpu_eh_ul_ipv6_toeplitz -mac_ipv4_gtpu_eh_dl_ipv6_udp_basic = 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)' +mac_ipv4_gtpu_eh_dl_ipv6_udp_basic = { + 'ipv6-udp': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)', + 'gtpogre-ipv6-udp': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)', +} mac_ipv4_gtpu_eh_dl_ipv6_udp_l3dst = { 'sub_casename': 'mac_ipv4_gtpu_eh_dl_ipv6_udp_l3dst', 'port_id': 0, 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l3-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2825,25 +3715,45 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_l3src_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l3-src-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=33').replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2855,25 +3765,45 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_l3src_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l3-src-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=32').replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_different', }, ] @@ -2885,25 +3815,45 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_l3dst_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l3-dst-only l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=33').replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33').replace('ABAB', '1212'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33').replace('ABAB', '1212'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2915,25 +3865,45 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_l3dst_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l3-dst-only l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32').replace('ABAB', '1212'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=32').replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32').replace('ABAB', '1212'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2944,22 +3914,39 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_l4dst = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l4-dst-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32') + .replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=32') + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32') .replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_different', }, ] @@ -2970,22 +3957,39 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_l4src = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp l4-src-only end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=32') + .replace('ABAB', '1212').replace('CDCD', '3434'), + 'action': 'check_hash_same', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=32') + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=32') .replace('ABAB', '1212').replace('CDCD', '3434'), 'action': 'check_hash_same', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -2997,29 +4001,53 @@ mac_ipv4_gtpu_eh_dl_ipv6_udp_all = { 'rule': 'flow create 0 ingress pattern eth / ipv4 / udp / gtpu / gtp_psc pdu_t is 0 / ipv6 / udp / end actions rss types ipv6-udp end key_len 0 queues end / end', 'test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], 'action': 'save_hash', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('sport=22', 'sport=32'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('sport=22', 'sport=32'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('dport=23', 'dport=33'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('dport=23', 'dport=33'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('CDCD', '3434'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('CDCD', '3434'), 'action': 'check_hash_different', }, { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic.replace('ABAB', '1212'), + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'].replace('ABAB', '1212'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], + 'action': 'save_hash', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('sport=22', 'sport=32'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('dport=23', 'dport=33'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('CDCD', '3434'), + 'action': 'check_hash_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'].replace('ABAB', '1212'), 'action': 'check_hash_different', }, ], 'post-test': [ { - 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic, + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['ipv6-udp'], + 'action': 'check_no_hash_or_different', + }, + { + 'send_packet': mac_ipv4_gtpu_eh_dl_ipv6_udp_basic['gtpogre-ipv6-udp'], 'action': 'check_no_hash_or_different', }, ] @@ -3060,6 +4088,14 @@ inner_l4_mac_ipv4_gtpu_ipv4_udp_tcp = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', 'action': 'check_hash_different', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/TCP(sport=22,dport=23)/("X"*480)', + 'action': 'save_hash', + }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', + 'action': 'check_hash_different', + }, ], 'post-test': [ { @@ -3070,6 +4106,14 @@ inner_l4_mac_ipv4_gtpu_ipv4_udp_tcp = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', 'action': 'check_hash_same_or_no_hash', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/TCP(sport=22,dport=23)/("X"*480)', + 'action': 'save_or_no_hash', + }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/IP(dst="192.168.0.1",src="192.168.0.2")/UDP(sport=22,dport=23)/("X"*480)', + 'action': 'check_hash_same_or_no_hash', + }, ] } inner_l4_mac_ipv6_gtpu_ipv4_udp_tcp = eval(str(inner_l4_mac_ipv4_gtpu_ipv4_udp_tcp) @@ -3077,7 +4121,8 @@ inner_l4_mac_ipv6_gtpu_ipv4_udp_tcp = eval(str(inner_l4_mac_ipv4_gtpu_ipv4_udp_t .replace('gtpu / ipv4', 'gtpu / gtp_psc / ipv4') .replace('IP()', 'IPv6()') .replace('teid=0x123456)', 'teid=0x123456)/GTPPDUSessionContainer(type=1, P=1, QFI=0x34)') - .replace('mac_ipv4', 'mac_ipv6')) + .replace('mac_ipv4', 'mac_ipv6') + .replace('IP(proto=0x2F)/GRE(proto=0x0800)', 'IPv6(nh=0x2F)/GRE(proto=0x86DD)')) inner_l4_mac_ipv4_gtpu_eh_ipv6_udp_tcp = { 'sub_casename': 'inner_l4_mac_ipv4_gtpu_eh_ipv6_udp_tcp', 'port_id': 0, @@ -3094,6 +4139,14 @@ inner_l4_mac_ipv4_gtpu_eh_ipv6_udp_tcp = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP(sport=22,dport=23)/("X"*480)', 'action': 'check_hash_different', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)', + 'action': 'save_hash', + }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP(sport=22,dport=23)/("X"*480)', + 'action': 'check_hash_different', + }, ], 'post-test': [ { @@ -3104,6 +4157,14 @@ inner_l4_mac_ipv4_gtpu_eh_ipv6_udp_tcp = { 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP(sport=22,dport=23)/("X"*480)', 'action': 'check_hash_same_or_no_hash', }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/UDP(sport=22,dport=23)/("X"*480)', + 'action': 'save_or_no_hash', + }, + { + 'send_packet': 'Ether(dst="00:11:22:33:44:55")/IP(proto=0x2F)/GRE(proto=0x0800)/IP()/UDP(dport=2152)/GTP_U_Header(gtp_type=255, teid=0x123456)/GTPPDUSessionContainer(type=0, P=1, QFI=0x34)/IPv6(src="ABAB:910B:6666:3457:8295:3333:1800:2929",dst="CDCD:910A:2222:5498:8475:1111:3900:2020")/TCP(sport=22,dport=23)/("X"*480)', + 'action': 'check_hash_same_or_no_hash', + }, ] } inner_l4_mac_ipv6_gtpu_eh_ipv6_udp_tcp = eval(str(inner_l4_mac_ipv4_gtpu_eh_ipv6_udp_tcp) @@ -3111,7 +4172,8 @@ inner_l4_mac_ipv6_gtpu_eh_ipv6_udp_tcp = eval(str(inner_l4_mac_ipv4_gtpu_eh_ipv6 .replace('pdu_t is 0', 'pdu_t is 1') .replace('(type=0', '(type=1') .replace('IP()', 'IPv6()') - .replace('mac_ipv4', 'mac_ipv6')) + .replace('mac_ipv4', 'mac_ipv6') + .replace('IP(proto=0x2F)/GRE(proto=0x0800)', 'IPv6(nh=0x2F)/GRE(proto=0x86DD)')) inner_l4_protocal_hash = [inner_l4_mac_ipv4_gtpu_ipv4_udp_tcp, inner_l4_mac_ipv6_gtpu_ipv4_udp_tcp, inner_l4_mac_ipv4_gtpu_eh_ipv6_udp_tcp, inner_l4_mac_ipv6_gtpu_eh_ipv6_udp_tcp] -- 2.17.1