summaryrefslogtreecommitdiff
path: root/debian/openssh-server.postinst
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2016-01-17 14:10:16 +0000
committerColin Watson <cjwatson@debian.org>2016-01-17 14:10:16 +0000
commit62242920b957dde2f376f8c170c55f339fd9e360 (patch)
treed427d07acd45bf4cf87c12fee6d94cb40974300a /debian/openssh-server.postinst
parent5f8dd74ff3bb2909239b46fc72c1e7620331aded (diff)
Remove protocol 1 host key generation from openssh-server.postinst (closes: #811265).
Diffstat (limited to 'debian/openssh-server.postinst')
-rw-r--r--debian/openssh-server.postinst20
1 files changed, 5 insertions, 15 deletions
diff --git a/debian/openssh-server.postinst b/debian/openssh-server.postinst
index 2c6c53d88..45121534d 100644
--- a/debian/openssh-server.postinst
+++ b/debian/openssh-server.postinst
@@ -79,18 +79,11 @@ host_keys_required() {
79 echo "$hostkeys" 79 echo "$hostkeys"
80 else 80 else
81 # No HostKey directives at all, so the server picks some 81 # No HostKey directives at all, so the server picks some
82 # defaults depending on the setting of Protocol. 82 # defaults.
83 protocol="$(get_config_option Protocol)" 83 echo /etc/ssh/ssh_host_rsa_key
84 [ "$protocol" ] || protocol=1,2 84 echo /etc/ssh/ssh_host_dsa_key
85 if echo "$protocol" | grep 1 >/dev/null; then 85 echo /etc/ssh/ssh_host_ecdsa_key
86 echo /etc/ssh/ssh_host_key 86 echo /etc/ssh/ssh_host_ed25519_key
87 fi
88 if echo "$protocol" | grep 2 >/dev/null; then
89 echo /etc/ssh/ssh_host_rsa_key
90 echo /etc/ssh/ssh_host_dsa_key
91 echo /etc/ssh/ssh_host_ecdsa_key
92 echo /etc/ssh/ssh_host_ed25519_key
93 fi
94 fi 87 fi
95} 88}
96 89
@@ -119,9 +112,6 @@ create_key() {
119create_keys() { 112create_keys() {
120 hostkeys="$(host_keys_required)" 113 hostkeys="$(host_keys_required)"
121 114
122 create_key "Creating SSH1 key; this may take some time ..." \
123 "$hostkeys" /etc/ssh/ssh_host_key -t rsa1
124
125 create_key "Creating SSH2 RSA key; this may take some time ..." \ 115 create_key "Creating SSH2 RSA key; this may take some time ..." \
126 "$hostkeys" /etc/ssh/ssh_host_rsa_key -t rsa 116 "$hostkeys" /etc/ssh/ssh_host_rsa_key -t rsa
127 create_key "Creating SSH2 DSA key; this may take some time ..." \ 117 create_key "Creating SSH2 DSA key; this may take some time ..." \