Stelnet(安全telnet)登陆也成为shh(sercure shell,安全外壳)登陆
-----------必要配置---------------
1、先根据加密算法生成秘钥对,用于传输数据时加密保护,保存在交换机中但不保存在配置文件中
[Huawei]rsa local-key-pair create
或
[Huawei]dsa local-key-pair create
举例:
[Huawei]rsa local-key-pair create
The key name will be: Huawei_Host
The 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]:1024 #设置密钥位数
Generating keys...
.................................................++++++
.++++++
............++++++++
..............................++++++++
[Huawei]
#客户端登陆SSH server服务端后自动获得分配钥匙
2、打开设备SSH(stelnet)服务端功能
[Huawei]stelnet server enable
3、创建SSH用户并指定其登陆验证方式
[Huawei]ssh user sshtest authentication-type ?
all Any authentication mode, any one of password, RSA, and DSA
dsa DSA authentication
password Password authentication
password-dsa Both password and DSA authentication modes
password-rsa Both password and RSA authentication modes
rsa RSA authentication
4、设置SSH用户服务类型
[Huawei]ssh user sshtest service-type ?
all Set all service type
sftp Set SFTP service type
stelnet Set Stelnet service type