Target Audience : Website Administrator

Before installing the latest version of OpenSSH, be sure to check the current version installed on your system using the following command:

From the result above, the installed OpenSSH version is 7.7.

To install the latest OpenSSH version, you must first install certain dependencies, i.e. development tools or build essentials and other required packages, as follows:

To create a suitable environment for the installation of the OpenSSH server version 8.0 onwards, it is necessary to create a new user and system group named "sshd", as well as a safe place for chroot.

Note: Generally, if you have an existing installation, this environment should already be present, you can skip this section and go to the next one. Otherwise, run the following commands:

At this point, download the OpenSSH tarball from any of the available HTTP mirrors or use the following wget command to download the file directly:

Then proceed with the installation:

Compile and Install SSH from Sources

$ ./configure --with-md5-passwords --with-pam --with-selinux --with-privsep-path=/var/lib/sshd/ --sysconfdir=/etc/ssh

$ make

$ sudo make install

Finally, restart ssh and check again what version is present: