Cisco Device Enable SSH login
設定特權(enable)模式密碼
(Config)#enable secret ccna開啟vty登入需先設定登入enable模式密碼,否則登入後將無法進入enable模式
設定本機帳號
(config)#username cisco secret ccna建立帳號cisco密碼nnca
secret代表密碼加密
產生加密key
(config)#ip domain-name ccna.com設定domain-name為ccna
(config)#crypto key generate rsa產生rsa金鑰How many bit in the modulus[512]:1024
使用 1024 bit加密(預設512)啟用SSH連線
(config)#ip ssh version 2使用ssh v2協定
(config)#line vty 0 4開啟0~4vty連線(即最大連線人數5人)
(config-line)#login local啟用密碼(login)及帳號(local)
(config-line)#transport input ssh啟用ssh
end
copy running-config startup-config返回及存檔
測試SSH連線
#ssh -l cisco 10.255.255.254另一Cisco裝置測試登入10.255.255.254 是路由器IP地址
或者使用Windows SSH 終端機
