summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2017-12-01 16:55:35 +1100
committerDarren Tucker <dtucker@zip.com.au>2017-12-01 16:55:35 +1100
commit79226e5413c5b0fda3511351a8511ff457e306d8 (patch)
tree07cf5dc0dbbbd03e96e6ce2bb32622569d4a4b39 /contrib
parent2937dd02c572a12f33d5c334d518f6cbe0b645eb (diff)
Remove RSA1 host key generation.
SSH1 support is now gone, remove SSH1 key generation. Patch from eb at emlix.com.
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/redhat/sshd.init1
-rwxr-xr-xcontrib/redhat/sshd.init.old17
2 files changed, 0 insertions, 18 deletions
diff --git a/contrib/redhat/sshd.init b/contrib/redhat/sshd.init
index 40c8dfd9f..8ee5fcd3b 100755
--- a/contrib/redhat/sshd.init
+++ b/contrib/redhat/sshd.init
@@ -40,7 +40,6 @@ start()
40 # Create keys if necessary 40 # Create keys if necessary
41 /usr/bin/ssh-keygen -A 41 /usr/bin/ssh-keygen -A
42 if [ -x /sbin/restorecon ]; then 42 if [ -x /sbin/restorecon ]; then
43 /sbin/restorecon /etc/ssh/ssh_host_key.pub
44 /sbin/restorecon /etc/ssh/ssh_host_rsa_key.pub 43 /sbin/restorecon /etc/ssh/ssh_host_rsa_key.pub
45 /sbin/restorecon /etc/ssh/ssh_host_dsa_key.pub 44 /sbin/restorecon /etc/ssh/ssh_host_dsa_key.pub
46 /sbin/restorecon /etc/ssh/ssh_host_ecdsa_key.pub 45 /sbin/restorecon /etc/ssh/ssh_host_ecdsa_key.pub
diff --git a/contrib/redhat/sshd.init.old b/contrib/redhat/sshd.init.old
index 0deb6080e..8a30f7da4 100755
--- a/contrib/redhat/sshd.init.old
+++ b/contrib/redhat/sshd.init.old
@@ -24,7 +24,6 @@ prog="sshd"
24# Some functions to make the below more readable 24# Some functions to make the below more readable
25KEYGEN=/usr/bin/ssh-keygen 25KEYGEN=/usr/bin/ssh-keygen
26SSHD=/usr/sbin/sshd 26SSHD=/usr/sbin/sshd
27RSA1_KEY=/etc/ssh/ssh_host_key
28RSA_KEY=/etc/ssh/ssh_host_rsa_key 27RSA_KEY=/etc/ssh/ssh_host_rsa_key
29DSA_KEY=/etc/ssh/ssh_host_dsa_key 28DSA_KEY=/etc/ssh/ssh_host_dsa_key
30PID_FILE=/var/run/sshd.pid 29PID_FILE=/var/run/sshd.pid
@@ -61,21 +60,6 @@ my_failure() {
61 ;; 60 ;;
62 esac 61 esac
63} 62}
64do_rsa1_keygen() {
65 if [ ! -s $RSA1_KEY ]; then
66 echo -n "Generating SSH1 RSA host key: "
67 if $KEYGEN -q -t rsa1 -f $RSA1_KEY -C '' -N '' >&/dev/null; then
68 chmod 600 $RSA1_KEY
69 chmod 644 $RSA1_KEY.pub
70 my_success "RSA1 key generation"
71 echo
72 else
73 my_failure "RSA1 key generation"
74 echo
75 exit 1
76 fi
77 fi
78}
79do_rsa_keygen() { 63do_rsa_keygen() {
80 if [ ! -s $RSA_KEY ]; then 64 if [ ! -s $RSA_KEY ]; then
81 echo -n "Generating SSH2 RSA host key: " 65 echo -n "Generating SSH2 RSA host key: "
@@ -119,7 +103,6 @@ do_restart_sanity_check() {
119case "$1" in 103case "$1" in
120 start) 104 start)
121 # Create keys if necessary 105 # Create keys if necessary
122 do_rsa1_keygen;
123 do_rsa_keygen; 106 do_rsa_keygen;
124 do_dsa_keygen; 107 do_dsa_keygen;
125 108