:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: iptables: Plain NAT test :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: [ 18:22:37 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 0) :: [ 18:22:38 ] :: [ PASS ] :: Command 'ip netns exec server sleep 1' (Expected 0, got 0) :: [ 18:22:39 ] :: [ PASS ] :: Command 'ip netns exec router iptables -t nat -A PREROUTING -i r_c -p tcp -j DNAT --to-destination 10.167.2.2:9999' (Expected 0, got 0) :: [ 18:22:39 ] :: [ PASS ] :: Command 'ip netns exec router iptables -t nat -A PREROUTING -i r_c -p udp -j DNAT --to-destination 10.167.2.2:9999' (Expected 0, got 0) :: [ 18:22:42 ] :: [ PASS ] :: Command 'ip netns exec server sleep 3' (Expected 0, got 0) :: [ 18:22:42 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 0) :: [ 18:22:42 ] :: [ PASS ] :: Command 'ip netns exec client ncat -4 10.167.1.254 8888' (Expected 0, got 0) :: [ 18:22:42 ] :: [ PASS ] :: Command 'ip netns exec client ncat -4 -u 10.167.1.254 8888' (Expected 0, got 0) :: [ 18:22:42 ] :: [ PASS ] :: Command 'ip netns exec router conntrack -L' (Expected 0, got 0) :: [ 18:22:42 ] :: [ PASS ] :: Command 'ip netns exec router iptables -t nat -A PREROUTING -i r_c -p sctp -j DNAT --to-destination 10.167.2.2:9999' (Expected 0, got 0) :: [ 18:22:45 ] :: [ PASS ] :: Command 'ip netns exec server sleep 3' (Expected 0, got 0) :: [ 18:22:45 ] :: [ PASS ] :: Command 'ip netns exec client timeout 5 sctp_test -H 10.167.1.1 -P 6013 -h 10.167.1.254 -p 8888 -s -c 1 -x 1 -X 1' (Expected 0, got 0) :: [ 18:22:45 ] :: [ PASS ] :: Command 'ip netns exec router conntrack -L' (Expected 0, got 0) :: [ 18:22:45 ] :: [ PASS ] :: Command 'ip netns exec router conntrack -F' (Expected 0, got 0) :: [ 18:22:47 ] :: [ PASS ] :: Command 'ip netns exec router sleep 2' (Expected 0, got 0) :: [ 18:22:47 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 143) :: [ 18:22:47 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 0) :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec router sleep 1' (Expected 0, got 0) :: [ 18:22:48 ] :: [ INFO ] :: Sending dnat.pcap as dnat.pcap :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec router iptables -tnat -nvL' (Expected 0, got 0) :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec router iptables -tnat -F' (Expected 0, got 0) :: [ 18:22:48 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 143) :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec router iptables -t nat -A POSTROUTING -o r_s -p tcp -j SNAT --to-source 10.167.2.254:1234' (Expected 0, got 0) :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec router iptables -t nat -A POSTROUTING -o r_s -p udp -j SNAT --to-source 10.167.2.254:1234' (Expected 0, got 0) :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec server iptables -A INPUT -i s_r -p tcp ! --sport 1234 -j DROP' (Expected 0, got 0) :: [ 18:22:48 ] :: [ PASS ] :: Command 'ip netns exec server iptables -A INPUT -i s_r -p udp ! --sport 1234 -j DROP' (Expected 0, got 0) :: [ 18:22:51 ] :: [ PASS ] :: Command 'ip netns exec server sleep 3' (Expected 0, got 0) :: [ 18:22:52 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 0) :: [ 18:22:52 ] :: [ PASS ] :: Command 'ip netns exec client ncat -4 10.167.2.2 9999' (Expected 0, got 0) :: [ 18:22:52 ] :: [ PASS ] :: Command 'ip netns exec client ncat -4 -u 10.167.2.2 9999' (Expected 0, got 0) :: [ 18:22:52 ] :: [ PASS ] :: Command 'ip netns exec router conntrack -L' (Expected 0, got 0) :: [ 18:22:52 ] :: [ PASS ] :: Command 'ip netns exec router iptables -t nat -A POSTROUTING -o r_s -p sctp -j SNAT --to-source 10.167.2.254:1234' (Expected 0, got 0) :: [ 18:22:52 ] :: [ PASS ] :: Command 'ip netns exec server iptables -A INPUT -i s_r -p sctp ! --sport 1234 -j DROP' (Expected 0, got 0) :: [ 18:22:55 ] :: [ PASS ] :: Command 'ip netns exec server sleep 3' (Expected 0, got 0) :: [ 18:22:55 ] :: [ PASS ] :: Command 'ip netns exec client timeout 5 sctp_test -H 10.167.1.1 -P 6013 -h 10.167.2.2 -p 9999 -s -c 1 -x 1 -X 1' (Expected 0, got 0) :: [ 18:22:55 ] :: [ PASS ] :: Command 'ip netns exec router conntrack -L' (Expected 0, got 0) :: [ 18:22:55 ] :: [ PASS ] :: Command 'ip netns exec router conntrack -F' (Expected 0, got 0) :: [ 18:22:57 ] :: [ PASS ] :: Command 'ip netns exec router sleep 2' (Expected 0, got 0) :: [ 18:22:57 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 143) :: [ 18:22:57 ] :: [ PASS ] :: Command 'ip netns exec router tcpdump -nni r_s -w snat.pcap' (Expected 0, got 0) :: [ 18:22:58 ] :: [ PASS ] :: Command 'ip netns exec router sleep 1' (Expected 0, got 0) :: [ 18:22:58 ] :: [ INFO ] :: Sending snat.pcap as snat.pcap :: [ 18:22:58 ] :: [ PASS ] :: Command 'ip netns exec router iptables -tnat -nvL' (Expected 0, got 0) :: [ 18:22:58 ] :: [ PASS ] :: Command 'ip netns exec router iptables -F' (Expected 0, got 0) :: [ 18:22:58 ] :: [ PASS ] :: Command 'ip netns exec server iptables -nvL' (Expected 0, got 0) :: [ 18:22:58 ] :: [ PASS ] :: Command 'ip netns exec server iptables -F' (Expected 0, got 0) :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: Duration: 21s :: Assertions: 42 good, 0 bad :: RESULT: PASS (iptables: Plain NAT test) :: [ 18:22:58 ] :: [ PASS ] :: NoCheck (Expected 0-255, got 143)