summaryrefslogtreecommitdiffstats
AgeCommit message (Expand)AuthorFilesLines
2019-10-21tls: enable tls engine as the default engineYu Ping1-1/+1
2019-10-21geneve: tests support python3Ole Troan1-1/+1
2019-10-21bonding: tests support python3Ole Troan1-2/+2
2019-10-21ip: test support python3Ole Troan1-33/+33
2019-10-21l2: tests support python3Ole Troan2-2/+2
2019-10-21acl: l2 classify test support python3Ole Troan1-2/+2
2019-10-21ipsec: tests support python3Ole Troan1-4/+4
2019-10-21classify: tests to support python3Ole Troan2-5/+12
2019-10-21bier: tests support python3Ole Troan2-9/+10
2019-10-21quic: Add PICOTLS_INCLUDE_DIR var to CMakeLists.Mathias Raoul1-0/+6
2019-10-21tests: add PID of VPP under test to API dump filename for the testAndrew Yourtchenko1-1/+2
2019-10-21ip: reassembly tests python3 supportOle Troan1-16/+13
2019-10-21session: support registration of custom crypto enginesFlorin Coras3-1/+22
2019-10-21vcl: add api to set lcl ipFlorin Coras5-7/+43
2019-10-21dhcp: python3 support in testsOle Troan2-40/+53
2019-10-20vlib: linux: fix wrong iommu_group value issue when using dpdk-pluginYulong Pei1-22/+19
2019-10-18vlib: enable worker-thread dispatch pcap traceDave Barach1-3/+7
2019-10-18mactime: fix handle_get_mactime fcn prototypeDave Barach1-4/+5
2019-10-18ip: add python3 support to punt testsOle Troan1-77/+50
2019-10-18map: python3 support in testsOle Troan1-8/+8
2019-10-18gso: python3 support in testsOle Troan1-5/+5
2019-10-18ip: ip vrf tests python3 supportOle Troan2-8/+2
2019-10-18udp:: support python3 in testsOle Troan1-2/+2
2019-10-18memif: add python3 support to testOle Troan2-20/+13
2019-10-18ip: trivial typos in docsPaul Vinciguerra2-9/+9
2019-10-18ipsec: make tests support python3Ole Troan4-27/+31
2019-10-17tests: python3 changes for span and aclplugin testsnaramre3-8/+8
2019-10-17session: unify buffer tx dispatchingFlorin Coras1-26/+11
2019-10-17http_static: pass http request type to builtin handlersDave Barach2-33/+60
2019-10-17classify: make tests support python3Ole Troan2-7/+6
2019-10-17session tcp: infra for transports to send buffersFlorin Coras4-60/+36
2019-10-17tests: python3 fixes for reassembly testssnaramre1-4/+4
2019-10-17tcp: avoid sending acks when data availableFlorin Coras3-5/+24
2019-10-17tests: python3 changes for load balancer testsnaramre1-1/+1
2019-10-17nat: tests support python3Ole Troan2-11/+10
2019-10-17vppinfra: test support python3Ole Troan1-1/+2
2019-10-17tcp: Init cwnd from ssthresh.Sergey Ivanushkin2-2/+38
2019-10-17http_static: add "http static cache clear" CLIDave Barach1-0/+75
2019-10-17ip: punt API cleanupJakub Grajciar1-6/+6
2019-10-17ip: rd_cp API cleanupJakub Grajciar1-4/+6
2019-10-17misc: Update gitignore for /test/ext/.dNeale Ranns1-0/+1
2019-10-17bonding: fix interface deletionBenoît Ganne1-15/+7
2019-10-17tcp: fix mss flag in option parsingFlorin Coras1-1/+1
2019-10-16session: increase max ctrl msg sizeFlorin Coras3-2/+13
2019-10-16tcp: avoid head retransmit if scoreboard has no holesFlorin Coras2-3/+2
2019-10-16bonding: graph node running after bond-input in feature arc may crashSteven Luong2-3/+42
2019-10-16cdp: fix non-null terminated vector useBenoît Ganne1-1/+1
2019-10-16dpdk: add function to add/del extra MAC addrsMatthew Smith1-0/+24
2019-10-16rdma: add rdma APIBenoît Ganne8-29/+401
2019-10-16flow: Add 'drop' and 'redirect-to-queue' actions supportChenmin Sun3-3/+30
(pkt) return pkts def test_srv6_mobile(self): """ test_srv6_mobile """ pkts = self.create_packets([("A::1", "B::1"), ("C::1", "D::1")]) self.vapi.cli( "sr localsid address {} behavior end.m.gtp4.e " .format(pkts[0]['IPv6'].dst) + "v4src_position 64 fib-table 0") self.logger.info(self.vapi.cli("show sr localsid")) self.vapi.cli("clear errors") self.pg0.add_stream(pkts) self.pg_enable_capture(self.pg_interfaces) self.pg_start() self.logger.info(self.vapi.cli("show errors")) self.logger.info(self.vapi.cli("show int address")) capture = self.pg1.get_capture(len(pkts)) for pkt in capture: self.logger.info(pkt.show2(dump=True)) self.assertEqual(pkt[IP].dst, self.ip4_dst) self.assertEqual(pkt[IP].src, self.ip4_src) self.assertEqual(pkt[GTP_U_Header].teid, 0xbbbbbbbb) class TestSRv6TMGTP4D(VppTestCase): """ SRv6 T.M.GTP4.D (GTP-U -> SRv6) """ @classmethod def setUpClass(cls): super(TestSRv6TMGTP4D, cls).setUpClass() try: cls.create_pg_interfaces(range(2)) cls.pg_if_i = cls.pg_interfaces[0] cls.pg_if_o = cls.pg_interfaces[1] cls.pg_if_i.config_ip4() cls.pg_if_i.config_ip6() cls.pg_if_o.config_ip4() cls.pg_if_o.config_ip6() cls.ip4_dst = "1.1.1.1" cls.ip4_src = "2.2.2.2" cls.ip6_dst = cls.pg_if_o.remote_ip6 for pg_if in cls.pg_interfaces: pg_if.admin_up() pg_if.resolve_arp() pg_if.resolve_ndp(timeout=5) except Exception: super(TestSRv6TMGTP4D, cls).tearDownClass() raise def create_packets(self, inner): ip4_dst = IPv4Address(str(self.ip4_dst)) ip4_src = IPv4Address(str(self.ip4_src)) self.logger.info("ip4 dst: {}".format(ip4_dst)) self.logger.info("ip4 src: {}".format(ip4_src)) pkts = list() for d, s in inner: pkt = (Ether() / IP(dst=str(ip4_dst), src=str(ip4_src)) / UDP(sport=2152, dport=2152) / GTP_U_Header(gtp_type="g_pdu", teid=200) / IPv6(dst=d, src=s) / UDP(sport=1000, dport=23)) self.logger.info(pkt.show2(dump=True)) pkts.append(pkt) return pkts def test_srv6_mobile(self): """ test_srv6_mobile """ pkts = self.create_packets([("A::1", "B::1"), ("C::1", "D::1")]) self.vapi.cli("set sr encaps source addr A1::1") self.vapi.cli("sr policy add bsid D4:: next D2:: next D3::") self.vapi.cli( "sr policy add bsid D5:: behavior t.m.gtp4.d D4::/32 " + "v6src_prefix C1::/64 nhtype ipv6 fib-table 0 drop-in") self.vapi.cli("sr steer l3 {}/32 via bsid D5::".format(self.ip4_dst)) self.vapi.cli("ip route add D2::/32 via {}".format(self.ip6_dst)) self.logger.info(self.vapi.cli("show sr steer")) self.logger.info(self.vapi.cli("show sr policies")) self.vapi.cli("clear errors") self.pg0.add_stream(pkts) self.pg_enable_capture(self.pg_interfaces) self.pg_start() self.logger.info(self.vapi.cli("show errors")) self.logger.info(self.vapi.cli("show int address")) capture = self.pg1.get_capture(len(pkts)) for pkt in capture: self.logger.info(pkt.show2(dump=True)) self.logger.info("GTP4.D Address={}".format( str(pkt[IPv6ExtHdrSegmentRouting].addresses[0]))) self.assertEqual( str(pkt[IPv6ExtHdrSegmentRouting].addresses[0]), "d4:0:101:101::c800:0") class TestSRv6EndMGTP6E(VppTestCase): """ SRv6 End.M.GTP6.E """ @classmethod def setUpClass(cls): super(TestSRv6EndMGTP6E, cls).setUpClass() try: cls.create_pg_interfaces(range(2)) cls.pg_if_i = cls.pg_interfaces[0] cls.pg_if_o = cls.pg_interfaces[1] cls.pg_if_i.config_ip6() cls.pg_if_o.config_ip6() cls.ip6_nhop = cls.pg_if_o.remote_ip6 for pg_if in cls.pg_interfaces: pg_if.admin_up() pg_if.resolve_ndp(timeout=5) except Exception: super(TestSRv6EndMGTP6E, cls).tearDownClass() raise def create_packets(self, inner): # 64bit prefix + 8bit QFI + 32bit TEID + 24bit dst = b'\xaa' * 8 + b'\x00' + \ b'\xbb' * 4 + b'\x00' * 3 ip6_dst = IPv6Address(dst) self.ip6_dst = ip6_dst src = b'\xcc' * 8 + \ b'\xdd' * 4 + b'\x11' * 4 ip6_src = IPv6Address(src) self.ip6_src = ip6_src pkts = list() for d, s in inner: pkt = (Ether() / IPv6(dst=str(ip6_dst), src=str(ip6_src)) / IPv6ExtHdrSegmentRouting(segleft=1, lastentry=0, tag=0, addresses=["a1::1"]) / IPv6(dst=d, src=s) / UDP(sport=1000, dport=23)) self.logger.info(pkt.show2(dump=True)) pkts.append(pkt) return pkts def test_srv6_mobile(self): """ test_srv6_mobile """ pkts = self.create_packets([("A::1", "B::1"), ("C::1", "D::1")]) self.vapi.cli( "sr localsid prefix {}/64 behavior end.m.gtp6.e fib-table 0" .format(pkts[0]['IPv6'].dst)) self.vapi.cli( "ip route add a1::/64 via {}".format(self.ip6_nhop)) self.logger.info(self.vapi.cli("show sr localsid")) self.vapi.cli("clear errors") self.pg0.add_stream(pkts) self.pg_enable_capture(self.pg_interfaces) self.pg_start() self.logger.info(self.vapi.cli("show errors")) self.logger.info(self.vapi.cli("show int address")) capture = self.pg1.get_capture(len(pkts)) for pkt in capture: self.logger.info(pkt.show2(dump=True)) self.assertEqual(pkt[IPv6].dst, "a1::1") self.assertEqual(pkt[IPv6].src, str(self.ip6_src)) self.assertEqual(pkt[GTP_U_Header].teid, 0xbbbbbbbb) class TestSRv6EndMGTP6D(VppTestCase): """ SRv6 End.M.GTP6.D """ @classmethod def setUpClass(cls): super(TestSRv6EndMGTP6D, cls).setUpClass() try: cls.create_pg_interfaces(range(2)) cls.pg_if_i = cls.pg_interfaces[0] cls.pg_if_o = cls.pg_interfaces[1] cls.pg_if_i.config_ip6() cls.pg_if_o.config_ip6() cls.ip6_nhop = cls.pg_if_o.remote_ip6 cls.ip6_dst = "2001::1" cls.ip6_src = "2002::1" for pg_if in cls.pg_interfaces: pg_if.admin_up() pg_if.resolve_ndp(timeout=5) except Exception: super(TestSRv6EndMGTP6D, cls).tearDownClass() raise def create_packets(self, inner): ip6_dst = IPv6Address(str(self.ip6_dst)) ip6_src = IPv6Address(str(self.ip6_src)) self.logger.info("ip6 dst: {}".format(ip6_dst)) self.logger.info("ip6 src: {}".format(ip6_src)) pkts = list() for d, s in inner: pkt = (Ether() / IPv6(dst=str(ip6_dst), src=str(ip6_src)) / UDP(sport=2152, dport=2152) / GTP_U_Header(gtp_type="g_pdu", teid=200) / IPv6(dst=d, src=s) / UDP(sport=1000, dport=23)) self.logger.info(pkt.show2(dump=True)) pkts.append(pkt) return pkts def test_srv6_mobile(self): """ test_srv6_mobile """ pkts = self.create_packets([("A::1", "B::1"), ("C::1", "D::1")]) self.vapi.cli("set sr encaps source addr A1::1") self.vapi.cli("sr policy add bsid D4:: next D2:: next D3::") self.vapi.cli( "sr localsid prefix 2001::/64 behavior end.m.gtp6.d " + "D4::/64 fib-table 0 drop-in") self.vapi.cli("ip route add D2::/64 via {}".format(self.ip6_nhop)) self.logger.info(self.vapi.cli("show sr policies")) self.logger.info(self.vapi.cli("show sr localsid")) self.vapi.cli("clear errors") self.pg0.add_stream(pkts) self.pg_enable_capture(self.pg_interfaces) self.pg_start() self.logger.info(self.vapi.cli("show errors")) self.logger.info(self.vapi.cli("show int address")) capture = self.pg1.get_capture(len(pkts)) for pkt in capture: self.logger.info(pkt.show2(dump=True)) self.logger.info("GTP6.D SID0={}".format( str(pkt[IPv6ExtHdrSegmentRouting].addresses[0]))) self.logger.info("GTP6.D SID1={}".format( str(pkt[IPv6ExtHdrSegmentRouting].addresses[1]))) self.assertEqual( str(pkt[IPv6ExtHdrSegmentRouting].addresses[0]), "2001::1") self.assertEqual( str(pkt[IPv6ExtHdrSegmentRouting].addresses[1]), "d4::c800:0")