Securing your SSH server

Standard
Enabling SSH on your home server – or a virtual private server, if you have one – is a risky affair. An unsecured server is a tempting target for script kiddies who want to test their “skills.” If you’re already running an ssh server, try the following command to see if anyone’s tried to connect to your computer and failed a password check:
user@computer:~$ sudo awk 'gsub(".*sshd.*Failed password for (invalid user )?", "") {print $1}' /var/log/auth.log* | sort | uniq -c | sort -rn | head -5
 11 root
 9 admin
 6 sales
 2 user

So how do you secure your ssh server so that inquisitive people across the globe can’t access and harm your sensitive data?

Continue reading