summaryrefslogtreecommitdiff
path: root/regress
diff options
context:
space:
mode:
authordtucker@openbsd.org <dtucker@openbsd.org>2019-07-23 07:39:43 +0000
committerDarren Tucker <dtucker@dtucker.net>2019-07-23 22:51:22 +1000
commit7e66b7d98c6e3f48a1918c3e1940c9b11b10ec63 (patch)
tree27360f172ef363799d6c4200efd1454eddfe826c /regress
parentfd0684b319e664d8821dc4ca3026126dfea3ccf4 (diff)
upstream: Only add ssh-dss to allowed key types if it's supported
by the binary. OpenBSD-Regress-ID: 395a54cab16e9e4ece9aec047ab257954eebd413
Diffstat (limited to 'regress')
-rw-r--r--regress/agent.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/regress/agent.sh b/regress/agent.sh
index 788b02064..48fa12b0e 100644
--- a/regress/agent.sh
+++ b/regress/agent.sh
@@ -1,4 +1,4 @@
1# $OpenBSD: agent.sh,v 1.14 2019/01/28 00:12:36 dtucker Exp $ 1# $OpenBSD: agent.sh,v 1.15 2019/07/23 07:39:43 dtucker Exp $
2# Placed in the Public Domain. 2# Placed in the Public Domain.
3 3
4tid="simple agent test" 4tid="simple agent test"
@@ -27,9 +27,6 @@ ${SSHKEYGEN} -q -N '' -t ed25519 -f $OBJ/user_ca_key \
27trace "overwrite authorized keys" 27trace "overwrite authorized keys"
28printf '' > $OBJ/authorized_keys_$USER 28printf '' > $OBJ/authorized_keys_$USER
29 29
30echo "PubkeyAcceptedKeyTypes +ssh-dss" >> $OBJ/ssh_proxy
31echo "PubkeyAcceptedKeyTypes +ssh-dss" >> $OBJ/sshd_proxy
32
33for t in ${SSH_KEYTYPES}; do 30for t in ${SSH_KEYTYPES}; do
34 # generate user key for agent 31 # generate user key for agent
35 rm -f $OBJ/$t-agent $OBJ/$t-agent.pub* 32 rm -f $OBJ/$t-agent $OBJ/$t-agent.pub*
@@ -75,6 +72,10 @@ fi
75 72
76for t in ${SSH_KEYTYPES}; do 73for t in ${SSH_KEYTYPES}; do
77 trace "connect via agent using $t key" 74 trace "connect via agent using $t key"
75 if [ "$t" = "ssh-dss" ]; then
76 echo "PubkeyAcceptedKeyTypes +ssh-dss" >> $OBJ/ssh_proxy
77 echo "PubkeyAcceptedKeyTypes +ssh-dss" >> $OBJ/sshd_proxy
78 fi
78 ${SSH} -F $OBJ/ssh_proxy -i $OBJ/$t-agent.pub -oIdentitiesOnly=yes \ 79 ${SSH} -F $OBJ/ssh_proxy -i $OBJ/$t-agent.pub -oIdentitiesOnly=yes \
79 somehost exit 52 80 somehost exit 52
80 r=$? 81 r=$?