配置路由器和交换机上的安全Shell运行的Cisco IOS
http://tech.ddvip.com 2007年12月19日 社区交流 收藏本文
内容摘要:本文讨论配置和调试安 全外壳(SSH)在运行的Cisco IOS软件的版本支持 SSH® Cisco 路由器或交换机。欲知关于特定 版本和软件镜象的,下面请参阅更多信息。
line vty 0 4
!--- Prevent non-SSH Telnets.
transport input ssh
我们测 试是确保的non-SSH用户不能远程登录到路由器卡特。
设置IOS 路由器或交换机作为SSH 客户端
有为启用SSH技术支持要求的四个步骤在IOS路由器。
配置 hostname命令。
配置DNS域。
生成将使用的SSH键。
启用SSH vtys的传输技术支持。
如果我们想要有一次设备操作作为SSH 客户端对其 他,我们能添加SSH到第二个设备,Reed。设备然后在客户端 服务器排列,用作为服务器和Reed的卡特作为客户端。 IOS SSH客户端配置在Reed是相同象为SSH 服务器配置需要 在卡特。
!--- Step 1: Configure hostname if you have not previously done so.
hostname carter
!--- aaa new-model causes the local username/password on the router
!--- to be used in the absence of other AAA statements.
aaa new-model
username cisco password 0 cisco
!--- Step 2: Configure the router's DNS domain.
ip domain-name rtp.cisco.com
!--- Step 3: Generate an SSH key to be used with SSH.
cry key generate rsa
ip ssh time-out 60
ip ssh authentication-retries 2
!--- Step 4: By default the vtys' transport is Telnet. In this case,
!--- Telnet has been disabled and only SSH is supported.
line vty 0 4
transport input SSH
!--- Instead of aaa new-model, the login local command may be used.
责编:豆豆技术应用