diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | regress/cfgmatch.sh | 21 |
2 files changed, 24 insertions, 2 deletions
@@ -62,6 +62,9 @@ | |||
62 | - markus@cvs.openbsd.org 2006/11/06 09:27:43 | 62 | - markus@cvs.openbsd.org 2006/11/06 09:27:43 |
63 | [regress/cfgmatch.sh] | 63 | [regress/cfgmatch.sh] |
64 | fix quoting for non-(c)sh login shells. | 64 | fix quoting for non-(c)sh login shells. |
65 | - dtucker@cvs.openbsd.org 2006/12/13 08:36:36 | ||
66 | [regress/cfgmatch.sh] | ||
67 | Additional test for multiple PermitOpen entries. ok djm@ | ||
65 | 68 | ||
66 | 20070927 | 69 | 20070927 |
67 | - (dtucker) [configure.ac atomicio.c] Fall back to including <sys/poll.h> if | 70 | - (dtucker) [configure.ac atomicio.c] Fall back to including <sys/poll.h> if |
@@ -3333,4 +3336,4 @@ | |||
3333 | OpenServer 6 and add osr5bigcrypt support so when someone migrates | 3336 | OpenServer 6 and add osr5bigcrypt support so when someone migrates |
3334 | passwords between UnixWare and OpenServer they will still work. OK dtucker@ | 3337 | passwords between UnixWare and OpenServer they will still work. OK dtucker@ |
3335 | 3338 | ||
3336 | $Id: ChangeLog,v 1.4773 2007/10/26 04:44:34 djm Exp $ | 3339 | $Id: ChangeLog,v 1.4774 2007/10/26 04:45:13 djm Exp $ |
diff --git a/regress/cfgmatch.sh b/regress/cfgmatch.sh index 46f26d089..35c5e52a1 100644 --- a/regress/cfgmatch.sh +++ b/regress/cfgmatch.sh | |||
@@ -1,4 +1,4 @@ | |||
1 | # $OpenBSD: cfgmatch.sh,v 1.3 2006/11/06 09:27:43 markus Exp $ | 1 | # $OpenBSD: cfgmatch.sh,v 1.4 2006/12/13 08:36:36 dtucker Exp $ |
2 | # Placed in the Public Domain. | 2 | # Placed in the Public Domain. |
3 | 3 | ||
4 | tid="sshd_config match" | 4 | tid="sshd_config match" |
@@ -104,3 +104,22 @@ for p in 1 2; do | |||
104 | fail "match override permitopen proto $p" | 104 | fail "match override permitopen proto $p" |
105 | stop_client | 105 | stop_client |
106 | done | 106 | done |
107 | |||
108 | cp $OBJ/sshd_proxy_bak $OBJ/sshd_proxy | ||
109 | echo "PermitOpen 127.0.0.1:1 127.0.0.1:$PORT 127.0.0.2:2" >>$OBJ/sshd_proxy | ||
110 | echo "Match User NoSuchUser" >>$OBJ/sshd_proxy | ||
111 | echo "PermitOpen 127.0.0.1:1 127.0.0.1:2" >>$OBJ/sshd_proxy | ||
112 | |||
113 | # Test that a rule that doesn't match doesn't override, plus test a | ||
114 | # PermitOpen entry that's not at the start of the list | ||
115 | for p in 1 2; do | ||
116 | rm -f $pidfile | ||
117 | trace "nomatch permitopen proxy w/key opts proto $p" | ||
118 | ${SSH} -q -$p $fwd -F $OBJ/ssh_proxy -f somehost \ | ||
119 | exec sh -c \'"echo \$\$ > $pidfile; exec sleep 100"\' >>$TEST_SSH_LOGFILE 2>&1 ||\ | ||
120 | fail "nomatch override permitopen proto $p sshd failed" | ||
121 | sleep 1; | ||
122 | ${SSH} -q -$p -p $fwdport -F $OBJ/ssh_config somehost true || \ | ||
123 | fail "nomatch override permitopen proto $p" | ||
124 | stop_client | ||
125 | done | ||