Skip to content

Instantly share code, notes, and snippets.

@v-thomp4
Created July 22, 2021 08:26
Show Gist options
  • Save v-thomp4/ab7d6e720a66ebe02cac83eb8329dbb7 to your computer and use it in GitHub Desktop.
Save v-thomp4/ab7d6e720a66ebe02cac83eb8329dbb7 to your computer and use it in GitHub Desktop.
upgrade openssh ubuntu 18.04
sudo apt install libpam0g-dev libselinux1-dev
sudo apt install build-essential zlib1g-dev libssl-dev
sudo mkdir /var/lib/sshd
sudo chmod -R 700 /var/lib/sshd/
sudo chown -R root:sys /var/lib/sshd/
sudo useradd -r -U -d /var/lib/sshd/ -c "sshd privsep" -s /bin/false sshd
wget -c https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-8.0p1.tar.gz
tar -xzf openssh-8.0p1.tar.gz
cd openssh-8.0p1/
./configure --with-md5-passwords --with-pam --with-selinux --with-privsep-path=/var/lib/sshd/ --sysconfdir=/etc/ssh
make
sudo make install
ssh -V
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment