aboutsummaryrefslogtreecommitdiffstats
path: root/doxygen
AgeCommit message (Expand)AuthorFilesLines
2018-08-03API: Remove legacy vlibsocket code.Ole Troan1-1/+0
2018-04-30Add reference to 18.04 test framework documentationChris Luke1-1/+3
2018-04-04Doc updates prior to branchChris Luke2-5/+9
2018-02-02Add link to 18.01 test framework documentation.Dave Wallace1-0/+1
2018-01-30VPP-899: Run VPP under SELinuxBilly McFall2-1/+2
2018-01-24docs: Clean up TOCDave Wallace1-0/+2
2017-12-15apps: refactor uri and update build infraFlorin Coras1-1/+0
2017-11-03Add C++ files to DoxygenChris Luke1-1/+1
2017-09-28General documentation updatesChris Luke6-5/+23
2017-09-25Add binary API documentationDave Barach1-0/+1
2017-06-22NAT64: documentationMatus Fabian1-0/+1
2017-06-09Sample plugin: Add sample plugin documentationRay Kinsella2-2/+2
2017-05-30Flowprobe: Stateful flows and IPv6, L4 recordingOle Troan1-1/+1
2017-05-10doxygen: Fix some pathsChris Luke1-1/+3
2017-05-05First commit SR MPLSPablo Camarillo1-0/+1
2017-03-29Bugfixing and documentation for SRv6Pablo Camarillo2-9/+10
2017-02-22Add ref to test framework docs in doxygen output.Dave Wallace2-5/+8
2017-02-02Added support for openSUSEMarco Varlese1-1/+4
2017-01-11Remove vcgn pluginDamjan Marion1-2/+1
2017-01-10Revert "vppctl: bash completion for vppctl commands"Damjan Marion1-8/+17
2017-01-09vppctl: bash completion for vppctl commandsPadraig Connolly1-17/+8
2017-01-01Move java,lua api and remaining plugins to src/Damjan Marion1-4/+3
2016-12-28Repair Doxygen build infrastructureChris Luke2-11/+29
2016-11-28Add support for using documentation siphons in multiple waysChris Luke19-32/+199
2016-11-28dpdk: add ipsec cryptodev supportSergio Gonzalez Monroy1-0/+1
2016-10-27Per-packet IPFIX record generation pluginDave Barach1-0/+1
2016-10-04Minor tweaks to hqos docChris Luke1-3/+4
2016-09-27Fix missing output in generated CLI/configChris Luke3-7/+8
2016-09-23Enable doc building on MacOSChris Luke1-1/+25
2016-09-21Refactor pre-Doxy siphon scripts; VPP-396Chris Luke24-657/+1486
2016-09-21Move doxytags file to html output directoryChris Luke1-1/+1
2016-09-21Copy the 16.09 release notes to masterChris Luke1-0/+1
2016-09-20Add structure to some of the documentation; VPP-223Chris Luke2-1/+15
2016-09-09Check for zero-sized Graphvix config file on Ubuntu; VPP-396Chris Luke1-1/+2
2016-09-09On Ubuntu check for graphviz system configChris Luke1-0/+3
2016-09-07VPP-346 Improve Doxygen include path mechanismChris Luke2-23/+55
2016-09-06VPP-346 More VPP doc fixesChris Luke3-15/+48
2016-09-02VPP-221 Improve doxygen dependency checkChris Luke1-1/+5
2016-09-01VPP-346 A swathe of doc fixesChris Luke4-16/+94
2016-08-31VPP-221 Loosen Doxygen CLI command struct parserChris Luke2-1/+2
2016-08-31VPP-221 CLI auto-documentation infrastructureChris Luke6-5/+793
2016-08-06Add DPDK definition to DOXYGENKeith Burns (alagalah)1-2/+3
2016-07-26Fix missing include dirs in doxygenChris Luke1-1/+1
2016-07-07Add some doxygen tagsDave Barach1-0/+1
2016-05-16VPP-57 Add missing license headers in doc filesChris Luke1-0/+22
2016-05-15VPP-62 Add a doxy filter to enable vpe.api docChris Luke3-5/+67
2016-05-13VPP-57 Add Doxygen to VPPChris Luke6-0/+2717
_address(src_ip_start, ip_prefix_len) dst_ip = self.get_ip_address(dst_ip_start, ip_prefix_len) p = (Ether(dst=src_if.local_mac, src=src_if.remote_mac) / ip_l(src=src_ip, dst=dst_ip) / UDP(sport=1234, dport=1234) / Raw(payload)) info.data = p.copy() size = random.choice(packet_sizes) self.extend_packet(p, size) pkts.append(p) return pkts def verify_capture(self, rx_if, capture, ip_l=IP): """Verify captured input packet stream for defined interface. :param VppInterface rx_if: Interface to verify captured packet stream. :param list capture: Captured packet stream. :param Scapy ip_l: Required IP layer - IP or IPv6. (Default is IP.) """ self.logger.info("Verifying capture on interface %s" % rx_if.name) count = 0 host_counters = {} for host_mac in rx_if._hosts_by_mac: host_counters[host_mac] = 0 for packet in capture: try: ip_received = packet[ip_l] payload_info = self.payload_to_info(str(packet[Raw])) packet_index = payload_info.index ip_sent = self._packet_infos[packet_index].data[ip_l] self.logger.debug("Got packet on port %s: src=%u (id=%u)" % (rx_if.name, payload_info.src, packet_index)) # Check standard fields self.assertIn(packet.dst, rx_if._hosts_by_mac, "Destination MAC address %s shouldn't be routed " "via interface %s" % (packet.dst, rx_if.name)) self.assertEqual(packet.src, rx_if.local_mac) self.assertEqual(ip_received.src, ip_sent.src) self.assertEqual(ip_received.dst, ip_sent.dst) host_counters[packet.dst] += 1 self._packet_infos.pop(packet_index) except: self.logger.error(ppp("Unexpected or invalid packet:", packet)) raise # We expect packet routed via all host of pg interface for host_mac in host_counters: nr = host_counters[host_mac] self.assertNotEqual( nr, 0, "No packet routed via host %s" % host_mac) self.logger.info("%u packets routed via host %s of %s interface" % (nr, host_mac, rx_if.name)) count += nr self.logger.info("Total amount of %u packets routed via %s interface" % (count, rx_if.name)) return count def create_ip_routes(self, dst_ip_net, dst_prefix_len, is_ipv6=0): """ Create IP routes for defined destination IP network. :param str dst_ip_net: Destination IP network. :param int dst_prefix_len: IP address prefix length. :param int is_ipv6: 0 if an ip4 route, else ip6 """ af = socket.AF_INET if is_ipv6 == 0 else socket.AF_INET6 dst_ip = socket.inet_pton(af, dst_ip_net) for pg_if in self.pg_interfaces[1:]: for nh_host in pg_if.remote_hosts: nh_host_ip = nh_host.ip4 if is_ipv6 == 0 else nh_host.ip6 next_hop_address = socket.inet_pton(af, nh_host_ip) next_hop_sw_if_index = pg_if.sw_if_index self.vapi.ip_add_del_route( dst_ip, dst_prefix_len, next_hop_address, next_hop_sw_if_index=next_hop_sw_if_index, is_ipv6=is_ipv6, is_multipath=1) self.logger.info("Route via %s on %s created" % (nh_host_ip, pg_if.name)) self.logger.debug(self.vapi.ppcli("show ip fib")) self.logger.debug(self.vapi.ppcli("show ip6 fib")) def test_ip_ecmp(self): """ IP equal-cost multi-path routing test """ src_ip_net = '16.0.0.1' dst_ip_net = '32.0.0.1' ip_prefix_len = 24 self.create_ip_routes(dst_ip_net, ip_prefix_len) pkts = self.create_stream(self.pg0, src_ip_net, dst_ip_net, ip_prefix_len, self.pg_if_packet_sizes) self.pg0.add_stream(pkts) self.pg_enable_capture(self.pg_interfaces) self.pg_start() # We expect packets on pg1, pg2 and pg3, but not on pg0 rx_count = 0 for pg_if in self.pg_interfaces[1:]: capture = pg_if._get_capture(timeout=1) self.assertNotEqual( len(capture), 0, msg="No packets captured on %s" % pg_if.name) rx_count += self.verify_capture(pg_if, capture) self.pg0.assert_nothing_captured(remark="IP packets forwarded on pg0") # Check that all packets were forwarded via pg1, pg2 and pg3 self.assertEqual(rx_count, len(pkts)) def test_ip6_ecmp(self): """ IPv6 equal-cost multi-path routing test """ src_ip_net = '3ffe:51::1' dst_ip_net = '3ffe:71::1' ip_prefix_len = 64 self.create_ip_routes(dst_ip_net, ip_prefix_len, is_ipv6=1) pkts = self.create_stream( self.pg0, src_ip_net, dst_ip_net, ip_prefix_len, self.pg_if_packet_sizes, ip_l=IPv6) self.pg0.add_stream(pkts) self.pg_enable_capture(self.pg_interfaces) self.pg_start() # We expect packets on pg1, pg2 and pg3, but not on pg0 rx_count = 0 for pg_if in self.pg_interfaces[1:]: capture = pg_if._get_capture(timeout=1) self.assertNotEqual( len(capture), 0, msg="No packets captured on %s" % pg_if.name) rx_count += self.verify_capture(pg_if, capture, ip_l=IPv6) self.pg0.assert_nothing_captured(remark="IP packets forwarded on pg0") # Check that all packets were forwarded via pg1, pg2 and pg3 self.assertEqual(rx_count, len(pkts)) if __name__ == '__main__': unittest.main(testRunner=VppTestRunner)