1# $OpenBSD: try-ciphers.sh,v 1.13 2012/06/28 05:07:45 dtucker Exp $ 2# Placed in the Public Domain. 3 4tid="try ciphers" 5 6ciphers="aes128-cbc 3des-cbc blowfish-cbc cast128-cbc 7 arcfour128 arcfour256 arcfour 8 aes192-cbc aes256-cbc rijndael-cbc@lysator.liu.se 9 aes128-ctr aes192-ctr aes256-ctr" 10macs="hmac-sha1 hmac-md5 umac-64@openssh.com hmac-sha1-96 hmac-md5-96 11 hmac-sha2-256hmac-sha2-512" 12 13for c in $ciphers; do 14 for m in $macs; do 15 trace "proto 2 cipher $c mac $m" 16 verbose "test $tid: proto 2 cipher $c mac $m" 17 ${SSH} -F $OBJ/ssh_proxy -2 -m $m -c $c somehost true 18 if [ $? -ne 0 ]; then 19 fail "ssh -2 failed with mac $m cipher $c" 20 fi 21 done 22done 23 24ciphers="3des blowfish" 25for c in $ciphers; do 26 trace "proto 1 cipher $c" 27 verbose "test $tid: proto 1 cipher $c" 28 ${SSH} -F $OBJ/ssh_proxy -1 -c $c somehost true 29 if [ $? -ne 0 ]; then 30 fail "ssh -1 failed with cipher $c" 31 fi 32done 33 34echo "Ciphers acss@openssh.org" >> $OBJ/sshd_proxy 35c=acss@openssh.org 36for m in $macs; do 37 trace "proto 2 $c mac $m" 38 verbose "test $tid: proto 2 cipher $c mac $m" 39 ${SSH} -F $OBJ/ssh_proxy -2 -m $m -c $c somehost true 40 if [ $? -ne 0 ]; then 41 fail "ssh -2 failed with mac $m cipher $c" 42 fi 43done 44