Skip to content

Commit

Permalink
Leverage dpkg-reconfigure to regenerate SSH keys
Browse files Browse the repository at this point in the history
  • Loading branch information
lirazsiri committed Aug 13, 2014
1 parent 5289221 commit 24a829f
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions firstboot.d/10regen-sshkeys
Expand Up @@ -4,7 +4,5 @@


echo "* Regenerating SSH cryptographic keys" echo "* Regenerating SSH cryptographic keys"


rm -f /etc/ssh/ssh_host_[dr]sa_key* rm -f /etc/ssh/*_key{,.pub}
ssh-keygen -q -f /etc/ssh/ssh_host_rsa_key -N '' -t rsa dpkg-reconfigure openssh-server
ssh-keygen -q -f /etc/ssh/ssh_host_dsa_key -N '' -t dsa

0 comments on commit 24a829f

Please sign in to comment.