]> andersk Git - gssapi-openssh.git/blobdiff - openssh/regress/login-timeout.sh
Import of OpenSSH 3.8.1p1
[gssapi-openssh.git] / openssh / regress / login-timeout.sh
diff --git a/openssh/regress/login-timeout.sh b/openssh/regress/login-timeout.sh
new file mode 100644 (file)
index 0000000..dfc6e6b
--- /dev/null
@@ -0,0 +1,29 @@
+#      $OpenBSD: login-timeout.sh,v 1.1 2004/02/17 08:23:20 dtucker Exp $
+#      Placed in the Public Domain.
+
+tid="connect after login grace timeout"
+
+trace "test login grace with privsep"
+echo "LoginGraceTime 10s" >> $OBJ/sshd_config
+echo "MaxStartups 1" >> $OBJ/sshd_config
+start_sshd
+
+(echo SSH-2.0-fake; sleep 60) | telnet localhost ${PORT} >/dev/null 2>&1 & 
+sleep 15
+${SSH} -F $OBJ/ssh_config somehost true
+if [ $? -ne 0 ]; then
+       fail "ssh connect after login grace timeout failed with privsep"
+fi
+
+kill `cat $PIDFILE`
+
+trace "test login grace without privsep"
+echo "UsePrivilegeSeparation no" >> $OBJ/sshd_config
+start_sshd
+
+(echo SSH-2.0-fake; sleep 60) | telnet localhost ${PORT} >/dev/null 2>&1 & 
+sleep 15
+${SSH} -F $OBJ/ssh_config somehost true
+if [ $? -ne 0 ]; then
+       fail "ssh connect after login grace timeout failed without privsep"
+fi
This page took 0.077219 seconds and 4 git commands to generate.