diff options
Diffstat (limited to 'regress/cert-hostkey.sh')
-rw-r--r-- | regress/cert-hostkey.sh | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/regress/cert-hostkey.sh b/regress/cert-hostkey.sh index c99c2b1c3..3f53922c8 100644 --- a/regress/cert-hostkey.sh +++ b/regress/cert-hostkey.sh | |||
@@ -1,11 +1,32 @@ | |||
1 | # $OpenBSD: cert-hostkey.sh,v 1.12 2015/07/03 04:39:23 djm Exp $ | 1 | # $OpenBSD: cert-hostkey.sh,v 1.13 2015/07/10 06:23:25 markus Exp $ |
2 | # Placed in the Public Domain. | 2 | # Placed in the Public Domain. |
3 | 3 | ||
4 | tid="certified host keys" | 4 | tid="certified host keys" |
5 | 5 | ||
6 | rm -f $OBJ/known_hosts-cert* $OBJ/host_ca_key* $OBJ/host_revoked_* | 6 | rm -f $OBJ/known_hosts-cert* $OBJ/host_ca_key* $OBJ/host_revoked_* |
7 | rm -f $OBJ/cert_host_key* $OBJ/host_krl_* | 7 | rm -f $OBJ/cert_host_key* $OBJ/host_krl_* |
8 | |||
9 | # Allow all hostkey/pubkey types, prefer certs for the client | ||
10 | types="" | ||
11 | for i in `$SSH -Q key`; do | ||
12 | if [ -z "$types" ]; then | ||
13 | types="$i" | ||
14 | continue | ||
15 | fi | ||
16 | case "$i" in | ||
17 | *cert*) types="$i,$types";; | ||
18 | *) types="$types,$i";; | ||
19 | esac | ||
20 | done | ||
21 | ( | ||
22 | echo "HostKeyAlgorithms ${types}" | ||
23 | echo "PubkeyAcceptedKeyTypes *" | ||
24 | ) >> $OBJ/ssh_proxy | ||
8 | cp $OBJ/sshd_proxy $OBJ/sshd_proxy_bak | 25 | cp $OBJ/sshd_proxy $OBJ/sshd_proxy_bak |
26 | ( | ||
27 | echo "HostKeyAlgorithms *" | ||
28 | echo "PubkeyAcceptedKeyTypes *" | ||
29 | ) >> $OBJ/sshd_proxy_bak | ||
9 | 30 | ||
10 | HOSTS='localhost-with-alias,127.0.0.1,::1' | 31 | HOSTS='localhost-with-alias,127.0.0.1,::1' |
11 | 32 | ||