system

rsa local-key-pair create


stelnet server enable



输入公钥






* * *

New Key from Linux ssh-keygen

```

system

rsa peer-public-key new


public-key-code begin

public-key-code end

peer-public-key end


```

配置ssh用户 

```

ssh user admin

ssh user admin authentication-type rsa

ssh user admin assign rsa-key new

ssh user admin service-type stelnet

```

如果没有使用ssh user命令配置相应的SSH用户,则可以直接执行

`ssh authentication-type default password`命令为用户配置SSH认证缺省采用密码认证,在用户数量比较多时,对用户使用缺省密码认证方式可以简化配置,此时只需再配置AAA用户即可。

* * *

```

user-interface con 0

set authentication password cipher sXXXXXX

aaa

local-user admin service-type ssh 

user-interface vty 0 4

protocol inbound ssh

user-interface vty 16 20

authentication-mode aaa

protocol inbound ssh