centos7 升级openssh up 8.6

#参考文档
https://www.cnblogs.com/cherishthepresent/p/16806148.html
https://cloud.tencent.com/developer/article/1745701
https://www.mhsxq.com/2023/03/21/ubuntu%E7%8E%AF%E5%A2%83%E5%8D%87%E7%BA%A7openssh%E7%89%88%E6%9C%AC/

#!/bin/bash
#mail:[email protected]
#centos7 update openssh to 8.6

mkdir openssh
cd openssh
 wget -c http://www.zlib.net/zlib-1.2.11.tar.gz
 wget -c  https://www.openssl.org/source/old/1.1.1/openssl-1.1.1.tar.gz
 wget -c https://openbsd.hk/pub/OpenBSD/OpenSSH/portable/openssh-8.6p1.tar.gz

 yum -y install   perl  perl-devel  pam-devel

 tar zxf zlib-1.2.11.tar.gz
 cd zlib-1.2.11
 ./configure --prefix=/usr/local/zlib
 make
 make install

 tar zxf openssl-1.1.1.tar.gz
 cd openssl-1.1.1
 ./config   --prefix=/usr/local/openssl
 make
 make install

 tar zxf openssh-8.6p1.tar.gz
 cd openssh-8.6p1

  ./configure  --prefix=/usr --sysconfdir=/etc/ssh --with-pam --with-zlib=/usr/local/zlib --with-ssl-dir=/etc/ssh --with-md5-passwords

  ssh -V

  

你可能感兴趣的:(centos7 升级openssh up 8.6)