für Debian / Ubuntu
Falls man eine VMware Maschine kopiert benötigt man neue SSH Keys. Folgende Zeilen generieren neue Keys.
sudo rm /etc/ssh/ssh_host_key sudo rm /etc/ssh/ssh_host_key.pub sudo rm /etc/ssh/ssh_host_rsa_key sudo rm /etc/ssh/ssh_host_rsa_key.pub sudo rm /etc/ssh/ssh_host_dsa_key sudo rm /etc/ssh/ssh_host_dsa_key.pub sudo /usr/bin/ssh-keygen -t rsa1 -f /etc/ssh/ssh_host_key -N "" sudo /usr/bin/ssh-keygen -t dsa -f /etc/ssh/ssh_host_dsa_key -N "" sudo /usr/bin/ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key -N ""
The new standard keys in the config file are:
HostKey /etc/ssh/ssh_host_rsa_key
HostKey /etc/ssh/ssh_host_ecdsa_key
HostKey /etc/ssh/ssh_host_ed25519_key
I propose to add „-b 4096“ to generate a hardened key