- (djm) [openbsd-compat/port-linux.c] Check whether SELinux is enabled
[openssh-git.git] / regress / proto-version.sh
blob1651a69e1fe0903f66979f857c3882592645966c
1 # $OpenBSD: proto-version.sh,v 1.3 2002/03/15 13:08:56 markus Exp $
2 # Placed in the Public Domain.
4 tid="sshd version with different protocol combinations"
6 # we just start sshd in inetd mode and check the banner
7 check_version ()
9 version=$1
10 expect=$2
11 banner=`echon | ${SSHD} -o "Protocol=${version}" -i -f ${OBJ}/sshd_proxy`
12 case ${banner} in
13 SSH-1.99-*)
14 proto=199
16 SSH-2.0-*)
17 proto=20
19 SSH-1.5-*)
20 proto=15
23 proto=0
25 esac
26 if [ ${expect} -ne ${proto} ]; then
27 fail "wrong protocol version ${banner} for ${version}"
31 check_version 2,1 199
32 check_version 1,2 199
33 check_version 2 20
34 check_version 1 15