Securing OpenSSH

While OpenSSH is generally more secure nowadays than it was in the past, it's still potentially a gaping hole in your server that miscreants will try to use in order to compromise your network. OpenSSH is very useful though; as administrators, we like OpenSSH because it gives us a convenient way of accessing multiple machines we manage all from one central computer. Securing OpenSSH isn't hard at all. In this section, I'll go over all the common ways in which you can secure OpenSSH on your servers. Specifically, I'll show you various tweaks you can make to the OpenSSH daemon's config file, which is /etc/ssh/sshd_config (covered in Chapter 4, Connecting to Networks). With each of the tweaks in this section, make sure you first ...

Get Mastering Ubuntu Server now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.