Configuring Console Interface Login Authentication on Huawei Switches

Topology

1. Authentication method 1: password (unsafe, enter the password)

<SW1>sys
[SW1]un in en
[SW1]sys SW1

# 进入用户控制台接口
[SW1]user-interface console 0

# 选择认证模式为密码方式
[SW1-ui-console0]authentication-mode password

# 设置密码
[SW1-ui-console0]set authentication password cipher 123456
[SW1-ui-console0]quit

PC1 reconnects and asks for password

2. Authentication method 2: AAA (recommended, user name and password are required) 

<SW1>sys
[SW1]un in en
[SW1]sys SW1

# 进入用户控制台接口
[SW1]user-interface console 0

# 认证模式为 aaa 方式
[SW1-ui-console0]authentication-mode aaa
[SW1-ui-console0]quit

# 进入 aaa 视图
[SW1]aaa

# 创建用户和密码
[SW1-aaa]local-user admin password cipher 123456

# 服务类型改为 terminal
[SW1-aaa]local-user admin service-type terminal
[SW1-aaa]quit

PC1 login, require user name to be entered first

Guess you like

Origin blog.csdn.net/mshxuyi/article/details/130081106