From c4dcb15036386cafac8ffe4c512dea931f9d5349 Mon Sep 17 00:00:00 2001 From: Matej Klotton Date: Tue, 6 Sep 2016 13:46:30 +0200 Subject: CSIT-353: MAP-T FIX: Add tx src mac to traffic script Change-Id: I011231c68dc470590323933dbdb3f33c3026559b Signed-off-by: Matej Klotton --- resources/traffic_scripts/send_ipv6_udp_check_map_t.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'resources/traffic_scripts/send_ipv6_udp_check_map_t.py') diff --git a/resources/traffic_scripts/send_ipv6_udp_check_map_t.py b/resources/traffic_scripts/send_ipv6_udp_check_map_t.py index af117c19be..2d9c291686 100755 --- a/resources/traffic_scripts/send_ipv6_udp_check_map_t.py +++ b/resources/traffic_scripts/send_ipv6_udp_check_map_t.py @@ -49,12 +49,14 @@ def _is_udp_in_ipv4(pkt): def main(): # pylint: disable=too-many-statements, too-many-locals """Main function of the script file.""" - args = TrafficScriptArg(['tx_dst_mac', 'tx_src_ipv6', 'tx_dst_ipv6', + args = TrafficScriptArg(['tx_dst_mac', 'tx_src_mac', + 'tx_src_ipv6', 'tx_dst_ipv6', 'tx_src_udp_port', 'rx_dst_mac', 'rx_src_mac', 'rx_src_ipv4', 'rx_dst_ipv4']) rx_if = args.get_arg('rx_if') tx_if = args.get_arg('tx_if') tx_dst_mac = args.get_arg('tx_dst_mac') + tx_src_mac = args.get_arg('tx_src_mac') tx_src_ipv6 = args.get_arg('tx_src_ipv6') tx_dst_ipv6 = args.get_arg('tx_dst_ipv6') tx_src_udp_port = int(args.get_arg('tx_src_udp_port')) @@ -70,7 +72,7 @@ def main(): # pylint: disable=too-many-statements, too-many-locals # Create empty UDP datagram in IPv6 - udp = (Ether(dst=tx_dst_mac) / + udp = (Ether(dst=tx_dst_mac, src=tx_src_mac) / IPv6(src=tx_src_ipv6, dst=tx_dst_ipv6) / UDP(sport=tx_src_udp_port, dport=tx_dst_udp_port) / 'udp_payload') -- cgit 1.2.3-korg