Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Making rpm package by openssh8.1

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

Due to the vulnerability of ssh scanned by security, it is relatively slow to upgrade ssh one by one to compile and install. Therefore, it is convenient to install and use the source code package into a rpm package.

Download the source package

Wget https://openbsd.hk/pub/OpenBSD/OpenSSH/portable/openssh-8.1p1.tar.gzwget http://ftp.riken.jp/Linux/momonga/6/Everything/SOURCES/x11-ssh-askpass-1.2.4.1.tar.gz makes packages for system 6, on system 6, and packages for system 7. Make it on the 7 system and download the related dependency package yum install rpm-build zlib-devel openssl-devel gcc perl-devel pam-devel unzip-y

4. Create the required directory

Mkdir-p / root/rpmbuild/ {SOURCES,SPECS} copy the required packages to cp openssh-8.1p1.tar.gz x11-ssh-askpass-1.2.4.1.tar.gz / root/rpmbuild/SOUR/SPECS/CEStar xf openssh-8.1p1.tar.gz cp openssh-8.1p1/contrib/redhat/openssh.spec / root/rpmbuild/SPECS under this directory

5. Modify the configuration file

Sed-I-e "s/%define no_x11_askpass 0/%define no_x11_askpass 1gamg" openssh.spec sed-I-e "s/%define no_gnome_askpass 0/%define no_gnome_askpass 1gamg" openssh.spec build package rpmbuild-ba openssh.spec errors encountered during compilation: error: build dependency failure: openssl-devel < 1.1 need to be solved by openssh-8.0p1-1.el7.x86_64: [root@ Localhost SPECS] # vim openssh.spec comment out BuildRequires: openssl-devel < 1.1 this line installation package rpm package in rpmbuild/RPMS/x86_64yum install-y. / openssh-* or rpm installation yum installation can automatically resolve dependencies It is recommended to enable the telnet service before upgrading. If the upgrade fails, you can roll back. Restart the service. Test the connection service sshd restart 6systemctl start sshd if the connection is not available. Just try to modify the configuration file PermitRootLogin yes to allow root to login PasswordAuthentication yes to allow login with a password

Refer to blog posts

Https://blog.csdn.net/ansible328/article/details/103016616https://www.cnblogs.com/fsckzy/p/10834550.html

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report