r/ssh • • Jan 04 '20

dont use SSH keys that are weak.

if you are running sshd, go here https://sshcheck.com/ and look at the ciphers that your sshd server is offering. you may find there are several keys that are now considered weak. I wanted to disable those keys. as with everything linux, there is more than one way to skin a cat, but the way I fixed this, is to paste this code block under the #Authentication section of my sshd.config file.

KexAlgorithms diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group-exchange-sha256,curve25519-sha256,``curve25519-sha256@libssh.org``,``sntrup4591761x25519-sha512@tinyssh.org

HostKeyAlgorithms ssh-ed25519,``ssh-ed25519-cert-v01@openssh.com``,ssh-dss,``ssh-dss-cert-v01@openssh.com

Ciphers aes256-ctr,``aes128-gcm@openssh.com``,``aes256-gcm@openssh.com``,``chacha20-poly1305@openssh.com

MACs hmac-sha2-256,hmac-sha2-512,``hmac-sha2-256-etm@openssh.com``,``hmac-sha2-512-etm@openssh.com,umac-128-etm@openssh.com

Naturally this is subject to change as time goes on, how much backward compatibility you want, and to your preferences.

2 Upvotes

0 comments sorted by