2017-04-30 23:34:55 +00:00
|
|
|
# $OpenBSD: proto-mismatch.sh,v 1.5 2017/04/30 23:34:55 djm Exp $
|
2002-05-01 03:17:33 +00:00
|
|
|
# Placed in the Public Domain.
|
|
|
|
|
|
|
|
tid="protocol version mismatch"
|
|
|
|
|
|
|
|
mismatch ()
|
|
|
|
{
|
|
|
|
client=$2
|
2017-04-30 23:34:55 +00:00
|
|
|
banner=`echo ${client} | ${SSHD} -i -f ${OBJ}/sshd_proxy`
|
2002-05-01 03:17:33 +00:00
|
|
|
r=$?
|
|
|
|
trace "sshd prints ${banner}"
|
|
|
|
if [ $r -ne 255 ]; then
|
2017-04-30 23:34:55 +00:00
|
|
|
fail "sshd prints ${banner} but accepts version ${client}"
|
2002-05-01 03:17:33 +00:00
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
2017-04-30 23:34:55 +00:00
|
|
|
mismatch SSH-1.5-HALLO
|