summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2013-03-12 11:19:40 +1100
committerDarren Tucker <dtucker@zip.com.au>2013-03-12 11:19:40 +1100
commitfe10a28e088751ec3a6ac96e73be21bae8b86d70 (patch)
tree39220c0f85435715900b6215e6ff19af1b5bbcae
parente4f43478228256ddbbce3b7f0c312ff5c707b667 (diff)
- (dtucker) [regress/Makefile regress/cipher-speed.sh regress/test-exec.sh]
Improve portability of cipher-speed test, based mostly on a patch from Iain Morgan.
-rw-r--r--ChangeLog5
-rw-r--r--regress/Makefile2
-rw-r--r--regress/cipher-speed.sh9
-rw-r--r--regress/test-exec.sh4
4 files changed, 14 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 3b5b5482..859c01ad 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+20120312
+ - (dtucker) [regress/Makefile regress/cipher-speed.sh regress/test-exec.sh]
+ Improve portability of cipher-speed test, based mostly on a patch from
+ Iain Morgan.
+
20130307
- (dtucker) [INSTALL] Bump documented autoconf version to what we're
currently using.
diff --git a/regress/Makefile b/regress/Makefile
index 779abf4f..6ef5d9cc 100644
--- a/regress/Makefile
+++ b/regress/Makefile
@@ -71,7 +71,7 @@ INTEROP_TESTS= putty-transfer putty-ciphers putty-kex conch-ciphers
USER!= id -un
CLEANFILES= t2.out t3.out t6.out1 t6.out2 t7.out t7.out.pub copy.1 copy.2 \
t8.out t8.out.pub t9.out t9.out.pub \
- authorized_keys_${USER} known_hosts pidfile \
+ authorized_keys_${USER} known_hosts pidfile testdata \
ssh_config sshd_config.orig ssh_proxy sshd_config sshd_proxy \
rsa.pub rsa rsa1.pub rsa1 host.rsa host.rsa1 \
rsa-agent rsa-agent.pub rsa1-agent rsa1-agent.pub \
diff --git a/regress/cipher-speed.sh b/regress/cipher-speed.sh
index 21bf0f2e..65e5f35e 100644
--- a/regress/cipher-speed.sh
+++ b/regress/cipher-speed.sh
@@ -5,12 +5,11 @@ tid="cipher speed"
getbytes ()
{
- sed -n '/transferred/s/.*secs (\(.* bytes.sec\).*/\1/p'
+ sed -n -e '/transferred/s/.*secs (\(.* bytes.sec\).*/\1/p' \
+ -e '/copied/s/.*s, \(.* MB.s\).*/\1/p'
}
tries="1 2"
-DATA=/bin/ls
-DATA=/bsd
ciphers="aes128-cbc 3des-cbc blowfish-cbc cast128-cbc
arcfour128 arcfour256 arcfour
@@ -26,7 +25,7 @@ config_defined HAVE_EVP_SHA256 && \
for c in $ciphers; do n=0; for m in $macs; do
trace "proto 2 cipher $c mac $m"
for x in $tries; do
- echon "$c/$m:\t"
+ printf "%-60s" "$c/$m:"
( ${SSH} -o 'compression no' \
-F $OBJ/ssh_proxy -2 -m $m -c $c somehost \
exec sh -c \'"dd of=/dev/null obs=32k"\' \
@@ -47,7 +46,7 @@ ciphers="3des blowfish"
for c in $ciphers; do
trace "proto 1 cipher $c"
for x in $tries; do
- echon "$c:\t"
+ printf "%-60s" "$c:"
( ${SSH} -o 'compression no' \
-F $OBJ/ssh_proxy -1 -c $c somehost \
exec sh -c \'"dd of=/dev/null obs=32k"\' \
diff --git a/regress/test-exec.sh b/regress/test-exec.sh
index bdc2c1a4..aa4e6e5c 100644
--- a/regress/test-exec.sh
+++ b/regress/test-exec.sh
@@ -140,6 +140,10 @@ if [ "x$TEST_SSH_LOGFILE" = "x" ]; then
TEST_SSH_LOGFILE=/dev/null
fi
+# Some data for test copies
+DATA=$OBJ/testdata
+cat $SSHD${EXEEXT} $SSHD${EXEEXT} $SSHD${EXEEXT} $SSHD${EXEEXT} >$DATA
+
# these should be used in tests
export SSH SSHD SSHAGENT SSHADD SSHKEYGEN SSHKEYSCAN SFTP SFTPSERVER SCP
#echo $SSH $SSHD $SSHAGENT $SSHADD $SSHKEYGEN $SSHKEYSCAN $SFTP $SFTPSERVER $SCP