summaryrefslogtreecommitdiff
path: root/regress/Makefile
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2011-01-24 11:46:57 +0000
committerColin Watson <cjwatson@debian.org>2011-01-24 11:46:57 +0000
commit0970072c89b079b022538e3c366fbfa2c53fc821 (patch)
treeb7024712d74234bb5a8b036ccbc9109e2e211296 /regress/Makefile
parent4e8aa4da57000c7bba8e5c49163bc0c0ca383f78 (diff)
parent478ff799463ca926a8dfbabf058f4e84aaffc65a (diff)
merge 5.7p1
Diffstat (limited to 'regress/Makefile')
-rw-r--r--regress/Makefile69
1 files changed, 50 insertions, 19 deletions
diff --git a/regress/Makefile b/regress/Makefile
index 9762ab204..f114c27e9 100644
--- a/regress/Makefile
+++ b/regress/Makefile
@@ -1,6 +1,6 @@
1# $OpenBSD: Makefile,v 1.54 2010/06/27 19:19:56 phessler Exp $ 1# $OpenBSD: Makefile,v 1.58 2011/01/06 22:46:21 djm Exp $
2 2
3REGRESS_TARGETS= t1 t2 t3 t4 t5 t6 t7 t-exec 3REGRESS_TARGETS= t1 t2 t3 t4 t5 t6 t7 t8 t9 t-exec
4tests: $(REGRESS_TARGETS) 4tests: $(REGRESS_TARGETS)
5 5
6# Interop tests are not run by default 6# Interop tests are not run by default
@@ -53,14 +53,20 @@ LTESTS= connect \
53 localcommand \ 53 localcommand \
54 forcecommand \ 54 forcecommand \
55 portnum \ 55 portnum \
56 keytype \
57 kextype \
56 cert-hostkey \ 58 cert-hostkey \
57 cert-userkey 59 cert-userkey \
60 host-expand
58 61
59INTEROP_TESTS= putty-transfer putty-ciphers putty-kex conch-ciphers 62INTEROP_TESTS= putty-transfer putty-ciphers putty-kex conch-ciphers
60#INTEROP_TESTS+=ssh-com ssh-com-client ssh-com-keygen ssh-com-sftp 63#INTEROP_TESTS+=ssh-com ssh-com-client ssh-com-keygen ssh-com-sftp
61 64
65#LTESTS= cipher-speed
66
62USER!= id -un 67USER!= id -un
63CLEANFILES= t2.out t6.out1 t6.out2 t7.out t7.out.pub copy.1 copy.2 \ 68CLEANFILES= t2.out t3.out t6.out1 t6.out2 t7.out t7.out.pub copy.1 copy.2 \
69 t8.out t8.out.pub t9.out t9.out.pub \
64 authorized_keys_${USER} known_hosts pidfile \ 70 authorized_keys_${USER} known_hosts pidfile \
65 ssh_config sshd_config.orig ssh_proxy sshd_config sshd_proxy \ 71 ssh_config sshd_config.orig ssh_proxy sshd_config sshd_proxy \
66 rsa.pub rsa rsa1.pub rsa1 host.rsa host.rsa1 \ 72 rsa.pub rsa rsa1.pub rsa1 host.rsa host.rsa1 \
@@ -69,45 +75,68 @@ CLEANFILES= t2.out t6.out1 t6.out2 t7.out t7.out.pub copy.1 copy.2 \
69 scp-ssh-wrapper.scp ssh_proxy_envpass remote_pid \ 75 scp-ssh-wrapper.scp ssh_proxy_envpass remote_pid \
70 sshd_proxy_bak rsa_ssh2_cr.prv rsa_ssh2_crnl.prv \ 76 sshd_proxy_bak rsa_ssh2_cr.prv rsa_ssh2_crnl.prv \
71 known_hosts-cert host_ca_key* cert_host_key* \ 77 known_hosts-cert host_ca_key* cert_host_key* \
72 putty.rsa2 sshd_proxy_orig \ 78 putty.rsa2 sshd_proxy_orig ssh_proxy_bak \
73 authorized_principals_${USER} 79 key.rsa-* key.dsa-* key.ecdsa-* \
80 authorized_principals_${USER} expect actual
74 81
75# Enable all malloc(3) randomisations and checks 82# Enable all malloc(3) randomisations and checks
76TEST_ENV= "MALLOC_OPTIONS=AFGJPRX" 83TEST_ENV= "MALLOC_OPTIONS=AFGJPRX"
77 84
85TEST_SSH_SSHKEYGEN?=ssh-keygen
86
78t1: 87t1:
79 ssh-keygen -if ${.CURDIR}/rsa_ssh2.prv | diff - ${.CURDIR}/rsa_openssh.prv 88 ${TEST_SSH_SSHKEYGEN} -if ${.CURDIR}/rsa_ssh2.prv | diff - ${.CURDIR}/rsa_openssh.prv
89 tr '\n' '\r' <${.CURDIR}/rsa_ssh2.prv > ${.OBJDIR}/rsa_ssh2_cr.prv
90 ${TEST_SSH_SSHKEYGEN} -if ${.OBJDIR}/rsa_ssh2_cr.prv | diff - ${.CURDIR}/rsa_openssh.prv
91 awk '{print $$0 "\r"}' ${.CURDIR}/rsa_ssh2.prv > ${.OBJDIR}/rsa_ssh2_crnl.prv
92 ${TEST_SSH_SSHKEYGEN} -if ${.OBJDIR}/rsa_ssh2_crnl.prv | diff - ${.CURDIR}/rsa_openssh.prv
80 93
81t2: 94t2:
82 cat ${.CURDIR}/rsa_openssh.prv > $(OBJ)/t2.out 95 cat ${.CURDIR}/rsa_openssh.prv > $(OBJ)/t2.out
83 chmod 600 $(OBJ)/t2.out 96 chmod 600 $(OBJ)/t2.out
84 ssh-keygen -yf $(OBJ)/t2.out | diff - ${.CURDIR}/rsa_openssh.pub 97 ${TEST_SSH_SSHKEYGEN} -yf $(OBJ)/t2.out | diff - ${.CURDIR}/rsa_openssh.pub
85 98
86t3: 99t3:
87 ssh-keygen -ef ${.CURDIR}/rsa_openssh.pub >$(OBJ)/rsa_secsh.pub 100 ${TEST_SSH_SSHKEYGEN} -ef ${.CURDIR}/rsa_openssh.pub >$(OBJ)/t3.out
88 ssh-keygen -if $(OBJ)/rsa_secsh.pub | diff - ${.CURDIR}/rsa_openssh.pub 101 ${TEST_SSH_SSHKEYGEN} -if $(OBJ)/t3.out | diff - ${.CURDIR}/rsa_openssh.pub
89 rm -f ${.CURDIR}/rsa_secsh.pub
90 102
91t4: 103t4:
92 ssh-keygen -lf ${.CURDIR}/rsa_openssh.pub |\ 104 ${TEST_SSH_SSHKEYGEN} -lf ${.CURDIR}/rsa_openssh.pub |\
93 awk '{print $$2}' | diff - ${.CURDIR}/t4.ok 105 awk '{print $$2}' | diff - ${.CURDIR}/t4.ok
94 106
95t5: 107t5:
96 ssh-keygen -Bf ${.CURDIR}/rsa_openssh.pub |\ 108 ${TEST_SSH_SSHKEYGEN} -Bf ${.CURDIR}/rsa_openssh.pub |\
97 awk '{print $$2}' | diff - ${.CURDIR}/t5.ok 109 awk '{print $$2}' | diff - ${.CURDIR}/t5.ok
98 110
99t6: 111t6:
100 ssh-keygen -if ${.CURDIR}/dsa_ssh2.prv > $(OBJ)/t6.out1 112 ${TEST_SSH_SSHKEYGEN} -if ${.CURDIR}/dsa_ssh2.prv > $(OBJ)/t6.out1
101 ssh-keygen -if ${.CURDIR}/dsa_ssh2.pub > $(OBJ)/t6.out2 113 ${TEST_SSH_SSHKEYGEN} -if ${.CURDIR}/dsa_ssh2.pub > $(OBJ)/t6.out2
102 chmod 600 $(OBJ)/t6.out1 114 chmod 600 $(OBJ)/t6.out1
103 ssh-keygen -yf $(OBJ)/t6.out1 | diff - $(OBJ)/t6.out2 115 ${TEST_SSH_SSHKEYGEN} -yf $(OBJ)/t6.out1 | diff - $(OBJ)/t6.out2
104 116
105$(OBJ)/t7.out: 117$(OBJ)/t7.out:
106 ssh-keygen -q -t rsa -N '' -f $@ 118 ${TEST_SSH_SSHKEYGEN} -q -t rsa -N '' -f $@
107 119
108t7: $(OBJ)/t7.out 120t7: $(OBJ)/t7.out
109 ssh-keygen -lf $(OBJ)/t7.out > /dev/null 121 ${TEST_SSH_SSHKEYGEN} -lf $(OBJ)/t7.out > /dev/null
110 ssh-keygen -Bf $(OBJ)/t7.out > /dev/null 122 ${TEST_SSH_SSHKEYGEN} -Bf $(OBJ)/t7.out > /dev/null
123
124$(OBJ)/t8.out:
125 ${TEST_SSH_SSHKEYGEN} -q -t dsa -N '' -f $@
126
127t8: $(OBJ)/t8.out
128 ${TEST_SSH_SSHKEYGEN} -lf $(OBJ)/t8.out > /dev/null
129 ${TEST_SSH_SSHKEYGEN} -Bf $(OBJ)/t8.out > /dev/null
130
131$(OBJ)/t9.out:
132 test "${TEST_SSH_ECC}" != yes || \
133 ${TEST_SSH_SSHKEYGEN} -q -t ecdsa -N '' -f $@
134
135t9: $(OBJ)/t9.out
136 test "${TEST_SSH_ECC}" != yes || \
137 ${TEST_SSH_SSHKEYGEN} -lf $(OBJ)/t9.out > /dev/null
138 test "${TEST_SSH_ECC}" != yes || \
139 ${TEST_SSH_SSHKEYGEN} -Bf $(OBJ)/t9.out > /dev/null
111 140
112t-exec: ${LTESTS:=.sh} 141t-exec: ${LTESTS:=.sh}
113 @if [ "x$?" = "x" ]; then exit 0; fi; \ 142 @if [ "x$?" = "x" ]; then exit 0; fi; \
@@ -123,3 +152,5 @@ t-exec-interop: ${INTEROP_TESTS:=.sh}
123 (env SUDO="${SUDO}" TEST_ENV=${TEST_ENV} sh ${.CURDIR}/test-exec.sh ${.OBJDIR} ${.CURDIR}/$${TEST}) || exit $$?; \ 152 (env SUDO="${SUDO}" TEST_ENV=${TEST_ENV} sh ${.CURDIR}/test-exec.sh ${.OBJDIR} ${.CURDIR}/$${TEST}) || exit $$?; \
124 done 153 done
125 154
155# Not run by default
156interop: ${INTEROP_TARGETS}