学海无涯
go,go,go

CVE-2017-15906漏洞修复

#下载文件:
wget "https://openbsd.hk/pub/OpenBSD/OpenSSH/portable/openssh-8.3p1.tar.gz"

#解压:
tar -zxvf openssh-8.3p1.tar.gz && cd openssh-8.3p1

#停止服务:
systemctl stop sshd

#删除历史文件:
yum remove openssh -y

#安装依赖:
yum install gcc openssl-devel zlib-devel -y

#执行安装:
./configure --prefix=/usr --sysconfdir=/etc/ssh --with-md5-passwords--with-pam --with-tcp-wrappers  --with-ssl-dir=/usr/bin/openssl --without-hardening
make && make install

#删除报错提示的key文件
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@         WARNING: UNPROTECTED PRIVATE KEY FILE!          @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Permissions 0640 for '/etc/ssh/ssh_host_ed25519_key' are too open.
It is required that your private key files are NOT accessible by others.
This private key will be ignored.
###############################
[root@proxy openssh-8.3p1]# rm -f /etc/ssh/ssh_host_ed25519_key

#修改/etc/ssh/sshd_config配置文件
 PermitRootLogin yes    #允许root登录

#配置自启动
cp contrib/redhat/sshd.init /etc/init.d/sshd
chkconfig --add sshd
chkconfig sshd on
chkconfig --list|grep sshd
service sshd start
ssh -V
赞(0) 打赏
未经允许不得转载:YYQ运维技术博客_运维的工作学习之路 » CVE-2017-15906漏洞修复
分享到: 更多 (0)

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

运维devops

联系我们关于本博客

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

微信扫一扫打赏