mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-02-10 00:37:00 +08:00
tests: separated the address ranges on full and unix tests and added IPv6 addresses
This commit is contained in:
@@ -209,7 +209,7 @@ device = vpns
|
|||||||
default-domain = example.com
|
default-domain = example.com
|
||||||
|
|
||||||
# The pool of addresses that leases will be given from.
|
# The pool of addresses that leases will be given from.
|
||||||
ipv4-network = 192.168.1.0
|
ipv4-network = 192.168.99.0
|
||||||
ipv4-netmask = 255.255.255.0
|
ipv4-netmask = 255.255.255.0
|
||||||
|
|
||||||
# The advertized DNS server. Use multiple lines for
|
# The advertized DNS server. Use multiple lines for
|
||||||
@@ -221,8 +221,8 @@ ipv4-netmask = 255.255.255.0
|
|||||||
#nbns = 192.168.1.3
|
#nbns = 192.168.1.3
|
||||||
|
|
||||||
# The IPv6 subnet that leases will be given from.
|
# The IPv6 subnet that leases will be given from.
|
||||||
#ipv6-network = fc00::
|
ipv6-network = fd60:d98f:7a84:dca6::
|
||||||
#ipv6-prefix = 16
|
ipv6-prefix = 64
|
||||||
|
|
||||||
# The domains over which the provided DNS should be used. Use
|
# The domains over which the provided DNS should be used. Use
|
||||||
# multiple lines for multiple domains.
|
# multiple lines for multiple domains.
|
||||||
|
|||||||
@@ -217,8 +217,8 @@ ipv4-netmask = 255.255.255.0
|
|||||||
#nbns = 192.168.1.3
|
#nbns = 192.168.1.3
|
||||||
|
|
||||||
# The IPv6 subnet that leases will be given from.
|
# The IPv6 subnet that leases will be given from.
|
||||||
#ipv6-network = fc00::
|
ipv6-network = fd91:6d87:7341:db6a::
|
||||||
#ipv6-prefix = 16
|
ipv6-prefix = 64
|
||||||
|
|
||||||
# The domains over which the provided DNS should be used. Use
|
# The domains over which the provided DNS should be used. Use
|
||||||
# multiple lines for multiple domains.
|
# multiple lines for multiple domains.
|
||||||
|
|||||||
@@ -94,14 +94,14 @@ rm -f pass.tmp
|
|||||||
sleep 5
|
sleep 5
|
||||||
|
|
||||||
# The client IP depends on the username so it shouldn't change.
|
# The client IP depends on the username so it shouldn't change.
|
||||||
ping -w 5 192.168.1.190
|
ping -w 5 192.168.99.190
|
||||||
if test $? != 0;then
|
if test $? != 0;then
|
||||||
kill $PID
|
kill $PID
|
||||||
echo "Cannot ping ocserv"
|
echo "Cannot ping ocserv"
|
||||||
stop
|
stop
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ping -w 5 192.168.1.190 -s 1500
|
ping -w 5 192.168.99.190 -s 1500
|
||||||
if test $? != 0;then
|
if test $? != 0;then
|
||||||
kill $PID
|
kill $PID
|
||||||
echo "Cannot ping ocserv"
|
echo "Cannot ping ocserv"
|
||||||
@@ -115,14 +115,14 @@ printf "echo root" >>echo-admin.tmp
|
|||||||
printf "\n" >>echo-admin.tmp
|
printf "\n" >>echo-admin.tmp
|
||||||
chmod 755 echo-admin.tmp
|
chmod 755 echo-admin.tmp
|
||||||
export SSH_ASKPASS="./echo-admin.tmp"
|
export SSH_ASKPASS="./echo-admin.tmp"
|
||||||
setsid ssh -T -F config.tmp root@192.168.1.190 occtl show user test >out.tmp 2>&1
|
setsid ssh -T -F config.tmp root@192.168.99.190 occtl show user test >out.tmp 2>&1
|
||||||
cat out.tmp
|
cat out.tmp
|
||||||
|
|
||||||
printf "#\!/bin/sh\n" >echo-admin.tmp
|
printf "#\!/bin/sh\n" >echo-admin.tmp
|
||||||
printf "echo root" >>echo-admin.tmp
|
printf "echo root" >>echo-admin.tmp
|
||||||
printf "\n" >>echo-admin.tmp
|
printf "\n" >>echo-admin.tmp
|
||||||
chmod 755 echo-admin.tmp
|
chmod 755 echo-admin.tmp
|
||||||
setsid ssh -T -F config.tmp root@192.168.1.190 occtl show user test >out.tmp 2>&1
|
setsid ssh -T -F config.tmp root@192.168.99.190 occtl show user test >out.tmp 2>&1
|
||||||
cat out.tmp
|
cat out.tmp
|
||||||
rm -f echo-admin.tmp
|
rm -f echo-admin.tmp
|
||||||
rm -f config.tmp
|
rm -f config.tmp
|
||||||
@@ -140,14 +140,14 @@ rm -f out.tmp
|
|||||||
# There is an issue in nuttcp that makes it crash under docker if
|
# There is an issue in nuttcp that makes it crash under docker if
|
||||||
# /proc/sys/net/ipv4/tcp_adv_win_scale does not exist.
|
# /proc/sys/net/ipv4/tcp_adv_win_scale does not exist.
|
||||||
|
|
||||||
#nuttcp -T 10 -t 192.168.1.190
|
#nuttcp -T 10 -t 192.168.99.190
|
||||||
#if test $? != 0;then
|
#if test $? != 0;then
|
||||||
# kill $PID
|
# kill $PID
|
||||||
# echo "Cannot send to ocserv"
|
# echo "Cannot send to ocserv"
|
||||||
# stop
|
# stop
|
||||||
#fi
|
#fi
|
||||||
|
|
||||||
#nuttcp -T 10 -r 192.168.1.190
|
#nuttcp -T 10 -r 192.168.99.190
|
||||||
#if test $? != 0;then
|
#if test $? != 0;then
|
||||||
# kill $PID
|
# kill $PID
|
||||||
# echo "Cannot recv from ocserv"
|
# echo "Cannot recv from ocserv"
|
||||||
|
|||||||
Reference in New Issue
Block a user