Openssh Portable



  1. Openssh Source Download
  2. Openssh Portable Windows Binary
  3. Openssh Portable Storage

Installing an OpenSSH server/client on a Windows 2016 server arms the user with a multi-function set of client/server utilities that facilitate a secure environment when logging into or transferring files to your windows server remotely. It also serves as a security management tool for your public/private key pairs. If you downloaded OpenSSH from the GitHub repo at PowerShell/openssh-portable, follow the instructions listed there, not the ones in this article. Windows の設定を使用して OpenSSH をインストールする Install OpenSSH using Windows Settings. Copssh packages portable OpenSSH, Cygwin and some popular utilites, plus implementing some best practices regarding security. OpenSSH is a FREE version of the SSH protocol suite of network connectivity tools. It encrypts all traffic (including passwords) to effectively eliminate eavesdropping, connection hijacking, and other network-level attacks.

Portable

centos7 升级openssh到openssh-8.0p1版本

环境介绍

centos7.3和centos7.6升级完毕测试登录ssh以及重启后登录ssh均无问题。

前期请自行配置好yum源(如果不会请百度)

整个过程不需要卸载原先的openssl包和openssh的rpm包。不影响我们的操作

本文的环境都是系统自带的openssh,没有经历过手动编译安装方式。如果之前有手动编译安装过openssh,请参照本文自行测试是否能成功。

./18-Apr-2021 17:07 - ChangeLog 18-Apr-2021 05 DJM-GPG-KEY.asc 17-Sep-2002 INSTALL 18-Apr-2021 17:07. Some third parties provide OpenSSL compatible engines. As for the binaries above the following disclaimer applies: Important Disclaimer: The listing of these third party products does not imply any endorsement by the OpenSSL project, and these organizations are not affiliated in any way with OpenSSL other than by the reference to their independent web sites here.

如果严格参照本文操作,我保证你升级没问题

centos7.6升级后的效果

centos7.3升级后的效果

如果ssh版本过低,最好先yum update openssh升级下到目前yum仓库默认的openssh7.4p1版本

默认centos7.3的ssh是如下版本

执行yum update openssh先升级下(反正官方提供的这种升级是没问题的。如果之前手动编译操作过openssh的升级,变更了默认配置文件路径什么的请自行测试。)

(这里准备统一openssh版本为7.4p1之后再统一编译安装升级到openssh8.0p1)

安装telnet-server以及xinetd

配置telnet

现在很多centos7版本安装telnet-server以及xinetd之后没有一个叫telnet的配置文件了。

如果下面telnet文件不存在的话,可以跳过这部分的更改

如果下面文件存在,请更改配置telnet可以root登录,把disable = no改成disable = yes

配置telnet登录的终端类型,在/etc/securetty文件末尾增加一些pts终端,如下

配置之后的显示

启动telnet服务,并设置开机自动启动

切换到telnet方式登录,以后的操作都在telnet终端下操作,防止ssh连接意外中断造成升级失败

telnet方式登录

安装依赖包

升级需要几个组件,有些是和编译相关的等

安装pam和zlib等(后面的升级操作可能没用到pam,安装上也没啥影响,如果不想安装pam请自行测试)

下载openssh包和openssl的包

我们都下载最新版本,下载箭头指的包

开始安装openssl

个人习惯把安装包或者工具之类的放下面目录。根据个人喜好随便放,不影响安装

备份下面2个文件或目录(如果存在的话就执行)

编译安装新版本的openssl

配置、编译、安装3个命令一起执行

&&符号表示前面的执行成功才会执行后面的

以上命令执行完毕,echo $?查看下最后的make install是否有报错,0表示没有问题

下面2个文件或者目录做软链接 (刚才前面的步骤mv备份过原来的)

命令行执行下面2个命令加载新配置

查看确认版本。没问题

安装openssh

Openssh Source Download

上传openssh的tar包并解压 War of roses for mac.

命令行删除原先ssh的配置文件和目录

然后配置、编译、安装

注意下面编译安装的命令是一行,请把第一行末尾的 去掉,然后在文本里弄成一行之后放命令行执行

参考下我的截图

安装完毕 检查下结果

修改配置文件最终为如下内容,其他的不要动

从原先的解压的包中拷贝一些文件到目标位置(如果目标目录存在就覆盖)

(可能下面的ssh.pam文件都没用到,因为sshd_config配置文件貌似没使用它,请自行测试。我这边是拷贝了)

Openssh Portable Windows Binary

把原先的systemd管理的sshd文件删除或者移走或者删除,不移走的话影响我们重启sshd服务

设置sshd服务开机启动

Openssh Portable Storage

接下来测试启停服务。都正常

Openssh portable storage

使用systemd方式也行

测试版本。都正常

如果不是生产机器。可以试着重启机器测试下登录sshd是否正常。我这边测试都没问题

测试没问题后可以把telnet服务关闭了

下面有一个神奇的二维码,扫一下您可能失去2元钱!

posted on 2019-04-27 19:55nmap 阅读(82652) 评论(33) 编辑收藏