1. 程式人生 > >華為 5700 配置ssh

華為 5700 配置ssh

inbound gre gen 成本 turn name type 完成 ilo

配置PC作為STelnet客戶端連接SSH服務器的示例配置PC作為STelnet客戶端連接SSH服務器的示例。在本示例中,通過在SSH服務器端生成本地密鑰對,並在SSH服務器端配置SSH用戶的用戶名和密碼,使能Stelnet服務,實現Stelnet客戶端連接SSH服務器。
組網需求如圖1所示,SSH服務器端STelnet服務使能後,STelnet客戶端可以通過Password、RSA、password-rsa或all認證的方式登錄到SSH服務器端。
配置登錄用戶Client001,密碼為“huawei”,登錄驗證方式為password。
服務器端IP地址是192.168.1.1。
用戶界面僅支持SSH協議。
圖1 配置PC作為STelnet客戶端連接SSH服務器組網圖

配置思路采用如下的思路配置PC作為STelnet客戶端連接SSH服務器:
用戶Client001的配置在SSH服務器上完成。
SSH服務器端STelnet服務使能。
配置SSH服務器端缺省的認證方式為password。

數據準備為完成此配置例,需準備如下的數據:
SSH用戶名及認證方式。
SSH用戶密碼。
SSH服務器名。

操作步驟
在服務器端生成本地密鑰對 system-view[Quidway] sysname SSH Server[SSH Server] rsa local-key-pair createThe key name will be: Quidway_HostThe range of public key size is (512 ~ 2048).NOTES: If the key modulus is greater than 512, It will take a few minutes.Input the bits in the modulus[default = 512]: 768Generating keys..........++++++++++++..........++++++++++++...................................++++++++......++++++++

在服務器端配置VTY用戶界面 [SSH Server] user-interface vty 0 4[SSH Server-ui-vty0-4] authentication-mode aaa[SSH Server-ui-vty0-4] protocol inbound ssh[SSH Server-ui-vty0-4] quit 說明: 若配置登錄協議為SSH,則S2300設備將自動禁止Telnet功能。

在服務器端配置SSH用戶的用戶名和密碼 [SSH Server] aaa[SSH Server-aaa] local-user client001 password cipher huawei[SSH Server-aaa] local-user client001 privilege level 3[SSH Server-aaa] local-user client001 service-type ssh[SSH Server-aaa] quit

使能STelent功能,並配置用戶的服務類型為STelnet [SSH Server] stelnet server enable[SSH Server] ssh authentication-type default password
驗證配置結果 # 通過putty軟件登錄設備,指定設備的IP地址192.168.1.1,並指定登錄方式為SSH。

通過putty軟件登錄設備,輸入用戶名和密碼,用戶名client001,密碼huawei。

配置文件
SSH服務器的配置文件

sysname SSH Server#aaa local-user client001 password cipher huaweilocal-user client001 privilege level 3 local-user client001 service-type ssh# stelnet server enable ssh authentication-type default password#user-interface vty 0 4 authentication-mode aaa protocol inbound ssh#return

華為 5700 配置ssh