From fd9361feaafe075c50c2a2a2a627553d097cb1b3 Mon Sep 17 00:00:00 2001 From: Jozsef Kadlecsik Date: Thu, 4 Apr 2013 16:32:20 +0200 Subject: Add new testsuite entries to verify counters and the new type implementations Signed-off-by: Jozsef Kadlecsik --- tests/check_sendip_packets | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 tests/check_sendip_packets (limited to 'tests/check_sendip_packets') diff --git a/tests/check_sendip_packets b/tests/check_sendip_packets new file mode 100644 index 0000000..0dad3d0 --- /dev/null +++ b/tests/check_sendip_packets @@ -0,0 +1,24 @@ +#!/bin/sh + +# -4|-6 dirs pkt-count + +set -e + +if [ "$1" = "-4" ]; then + cmd=iptables + proto=ipv4 + src=10.255.255.64 + dst=127.0.0.1 +else + cmd=ip6tables + proto=ipv6 + src=1002:1002:1002:1002::32 + dst=::1 +fi + +$cmd -A INPUT -m set --match-set test $2 -j DROP +for x in `seq 1 $3`; do + sendip -p $proto -id $dst -is $src -p tcp -td 80 -ts 1025 $dst +done +$cmd -D INPUT -m set --match-set test $2 -j DROP + -- cgit v1.2.3