summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--regress/forwarding.sh9
1 files changed, 6 insertions, 3 deletions
diff --git a/regress/forwarding.sh b/regress/forwarding.sh
index 42d9f65d1..0eee3176a 100644
--- a/regress/forwarding.sh
+++ b/regress/forwarding.sh
@@ -1,4 +1,4 @@
1# $OpenBSD: forwarding.sh,v 1.13 2015/02/21 20:51:02 djm Exp $ 1# $OpenBSD: forwarding.sh,v 1.14 2015/02/23 20:32:15 djm Exp $
2# Placed in the Public Domain. 2# Placed in the Public Domain.
3 3
4tid="local and remote forwarding" 4tid="local and remote forwarding"
@@ -10,6 +10,9 @@ start_sshd
10base=33 10base=33
11last=$PORT 11last=$PORT
12fwd="" 12fwd=""
13CTL=$OBJ/ctl-sock
14rm -f $CTL
15
13for j in 0 1 2; do 16for j in 0 1 2; do
14 for i in 0 1 2; do 17 for i in 0 1 2; do
15 a=$base$j$i 18 a=$base$j$i
@@ -109,7 +112,7 @@ echo "LocalForward ${base}01 127.0.0.1:$PORT" >> $OBJ/ssh_config
109echo "RemoteForward ${base}02 127.0.0.1:${base}01" >> $OBJ/ssh_config 112echo "RemoteForward ${base}02 127.0.0.1:${base}01" >> $OBJ/ssh_config
110for p in 1 2; do 113for p in 1 2; do
111 trace "config file: start forwarding, fork to background" 114 trace "config file: start forwarding, fork to background"
112 ${SSH} -$p -F $OBJ/ssh_config -f somehost sleep 10 115 ${SSH} -S $CTL -M -$p -F $OBJ/ssh_config -f somehost sleep 10
113 116
114 trace "config file: transfer over forwarded channels and check result" 117 trace "config file: transfer over forwarded channels and check result"
115 ${SSH} -F $OBJ/ssh_config -p${base}02 -o 'ConnectionAttempts=4' \ 118 ${SSH} -F $OBJ/ssh_config -p${base}02 -o 'ConnectionAttempts=4' \
@@ -117,7 +120,7 @@ for p in 1 2; do
117 test -s ${COPY} || fail "failed copy of ${DATA}" 120 test -s ${COPY} || fail "failed copy of ${DATA}"
118 cmp ${DATA} ${COPY} || fail "corrupted copy of ${DATA}" 121 cmp ${DATA} ${COPY} || fail "corrupted copy of ${DATA}"
119 122
120 wait 123 ${SSH} -S $CTL -O exit somehost
121done 124done
122 125
123for p in 2; do 126for p in 2; do