tests: check whether the firewall rules have been applied with restrict-user-to-routes

This commit is contained in:
Nikos Mavrogiannopoulos
2015-11-23 17:26:57 +01:00
parent 5952dfbece
commit ddddaee5be
7 changed files with 521 additions and 9 deletions

View File

@@ -91,21 +91,21 @@ PID=`cat ${srcdir}/pid1.$$`
# The client IP depends on the username so it shouldn't change.
ping -w 5 192.168.79.1
if test $? != 0;then
kill $PID
kill -INT $PID
echo "Cannot ping ocserv"
stop
fi
ping -w 5 192.168.79.1 -s 1500
if test $? != 0;then
kill $PID
kill -INT $PID
echo "Cannot ping ocserv"
stop
fi
ping6 -w 5 fd91:6d87:7341:db6a::1
if test $? != 0;then
kill $PID
kill -INT $PID
echo "Cannot ping the IPv6 of ocserv"
stop
fi
@@ -119,7 +119,7 @@ nuttcp -T 10 -t 192.168.79.1
if test $? != 0;then
echo "Cannot send to ocserv"
exit 77
kill $PID
kill -INT $PID
stop
fi
@@ -127,14 +127,14 @@ nuttcp -T 10 -r 192.168.79.1
if test $? != 0;then
echo "Cannot recv from ocserv"
exit 77
kill $PID
kill -INT $PID
stop
fi
fi
sleep 2
kill $PID
kill -INT $PID
sleep 4