Conselo pc登录交换机
密码认证(不安全)
# 进入用户视图
system-view
# 进入Console接口0
user-interface console 0
# 选择类型
authentication-mode password
# 选择密码类型(明文与密文两种)
set authentication password cipher abc123
set authentication password simple abc123
当退出交换机视图之后,需输入密码之后才能进入交换机视图里。但只涉及到密码,但这并不安全。
AAA认证
# 进入Console接口0
user-interface console 0
# 选择类型aaa
authentication-mode aaa
# 进入aaa视图
aaa
# 配置用户和密码
local-user huawei password cipher hcip
# 将指定服务器类型
local-user huawei service-type terminal
现在的登录交换机需要进行输入用户名和密码才能登录视图,之后后续操作内容。
Telnet 网络设备之间远程配置登录
密码认证(不安全)
# 进入虚拟终端配置
user-interface vty 0 4
# 配置类型
authentication-mode password
# 配置密码
set authentication password simple abc123
# 建立vlan1
vlan 1
# 进入端口
int g0/0/1
# 端口类型配置(access)
port link-type access
# 加入端口vlan1
port default vlan 1
# 进入vlan1
int vlan 1
# 配置IP地址
ip address 192.168.1.1 24
当进行视图界面telnet连接虚拟终端后,输入密码进入界面。但安全低,所以建议使用aaa模式下的账户密码认证。
AAA认证
# 进入虚拟终端配置
user-interface vty 0 4
# 配置类型aaa
authentication-mode aaa
# 进入aaa视图
aaa
# 配置账号密码
local-user huawei password cipher hcip
# 配置服务类型
local-user huawei service-type telnet
# 建立vlan1
vlan 1
# 进入端口
int g0/0/1
# 端口类型配置(access)
port link-type access
# 加入端口vlan1
port default vlan 1
# 进入vlan1
int vlan 1
# 配置IP地址
ip address 192.168.1.1 24
当配置aaa,利用账号密码进行登录后;才能后续操作。也可以在添加账号密码的后边leve等级进行限制管理。
SSH登录配置
服务器端配置
# 开启ssh服务器
stelnet server enable
# 配置ssh用户认证模式创建
ssh user admin authentication-type password
# 配置服务类型
ssh user admin service-type stelnet
# 配置虚拟终端
user-interface vty 0 4
# 配置认证方式aaa
authentication-mode aaa
# 指定类型
protocol inbound ssh
# 进入aaa
aaa
# 配置账号密码
local-user admin password simple huawei
# 配置服务类型
local-user admin service-type ssh
# 配置账户等级权限
local-user admin privilege level 15
# 密钥
rsa local-key-pair create
# 建立vlan1
vlan 1
# 进入端口
int e0/0/2
# 端口类型配置(access)
port link-type access
# 加入端口vlan1
port default vlan 1
# 进入vlan1
int vlan 1
# 配置IP地址
ip address 192.168.1.1 24
客户端配置
# 开启ssh配置服务器
stelnet server enable
# 开启客户端
ssh client first-time enable
# 建立vlan1
vlan 1
# 进入端口
int e0/0/2
# 端口类型配置(access)
port link-type access
# 加入端口vlan1
port default vlan 1
# 进入vlan1
int vlan 1
# 配置IP地址
ip address 192.168.1.1 24
利用ssh对网络设备之间互相建立连接,ssh的作用对远程设备的连接建立了安全保障,可靠的文件传输以及加密形式端口的转发。
当实现远程登录设备时,可以利用level权限进行限制使用者的操作权限!