diff options
author | Darren Tucker <dtucker@zip.com.au> | 2003-06-18 22:18:57 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2003-06-18 22:18:57 +1000 |
commit | fc8a7ea202046052d074931b4e9c07b505b8a1df (patch) | |
tree | 4686b387f062a8b95b5c0037ad89283bacaefe22 /regress/reconfigure.sh | |
parent | 0275b52387cfca184be6947cac6f493ea5161e24 (diff) |
- (dtucker) [reconfigure.sh rekey.sh sftp-badcmds.sh]
Import new regression tests from OpenBSD
Diffstat (limited to 'regress/reconfigure.sh')
-rw-r--r-- | regress/reconfigure.sh | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/regress/reconfigure.sh b/regress/reconfigure.sh new file mode 100644 index 000000000..1de846a7e --- /dev/null +++ b/regress/reconfigure.sh | |||
@@ -0,0 +1,28 @@ | |||
1 | # $OpenBSD: reconfigure.sh,v 1.1 2003/06/12 15:43:32 markus Exp $ | ||
2 | # Placed in the Public Domain. | ||
3 | |||
4 | tid="simple connect after reconfigure" | ||
5 | |||
6 | # we need the full path to sshd for -HUP | ||
7 | SSHD=/usr/sbin/sshd | ||
8 | |||
9 | start_sshd | ||
10 | |||
11 | kill -HUP `cat $PIDFILE` | ||
12 | sleep 1 | ||
13 | |||
14 | trace "wait for sshd to restart" | ||
15 | i=0; | ||
16 | while [ ! -f $PIDFILE -a $i -lt 10 ]; do | ||
17 | i=`expr $i + 1` | ||
18 | sleep $i | ||
19 | done | ||
20 | |||
21 | test -f $PIDFILE || fatal "sshd did not restart" | ||
22 | |||
23 | for p in 1 2; do | ||
24 | ${SSH} -o "Protocol=$p" -F $OBJ/ssh_config somehost true | ||
25 | if [ $? -ne 0 ]; then | ||
26 | fail "ssh connect with protocol $p failed after reconfigure" | ||
27 | fi | ||
28 | done | ||