-# Activate Twisted Conch tests if the binary is present
-REGRESS_INTEROP_CONCH=no
-if test -x "$CONCH" ; then
- REGRESS_INTEROP_CONCH=yes
-fi
-
-# If PuTTY is present and we are running a PuTTY test, prepare keys and
-# configuration
-REGRESS_INTEROP_PUTTY=no
-if test -x "$PUTTYGEN" -a -x "$PLINK" ; then
- REGRESS_INTEROP_PUTTY=yes
-fi
-case "$SCRIPT" in
-*putty*) ;;
-*) REGRESS_INTEROP_PUTTY=no ;;
-esac
-
-if test "$REGRESS_INTEROP_PUTTY" = "yes" ; then
- mkdir -p ${OBJ}/.putty
-
- # Add a PuTTY key to authorized_keys
- rm -f ${OBJ}/putty.rsa2
- puttygen -t rsa -o ${OBJ}/putty.rsa2 < /dev/null > /dev/null
- puttygen -O public-openssh ${OBJ}/putty.rsa2 \
- >> $OBJ/authorized_keys_$USER
-
- # Convert rsa2 host key to PuTTY format
- ${SRC}/ssh2putty.sh 127.0.0.1 $PORT $OBJ/rsa > \
- ${OBJ}/.putty/sshhostkeys
- ${SRC}/ssh2putty.sh 127.0.0.1 22 $OBJ/rsa >> \
- ${OBJ}/.putty/sshhostkeys
-
- # Setup proxied session
- mkdir -p ${OBJ}/.putty/sessions
- rm -f ${OBJ}/.putty/sessions/localhost_proxy
- echo "Hostname=127.0.0.1" >> ${OBJ}/.putty/sessions/localhost_proxy
- echo "PortNumber=$PORT" >> ${OBJ}/.putty/sessions/localhost_proxy
- echo "ProxyMethod=5" >> ${OBJ}/.putty/sessions/localhost_proxy
- echo "ProxyTelnetCommand=sh ${SRC}/sshd-log-wrapper.sh ${SSHD} ${TEST_SSH_LOGFILE} -i -f $OBJ/sshd_proxy" >> ${OBJ}/.putty/sessions/localhost_proxy
-
- REGRESS_INTEROP_PUTTY=yes
-fi
-