文本版|topic 高级搜索
   名人堂 帮助 论坛制度 意见反馈 | 首页 博客 周新贴 招聘 专题 新闻
RSS 底部
 
社区导航: 专家门诊   网络技术   操作系统   数据库   程序设计   系统应用   考试认证   CIO及信息化   站长交流   综合交流   下载基地  51CTO产品服务 设为首页 | 收藏本站
51CTO技术论坛» 思科技术 » 交换机访问控制       [ 打印]  [ 订阅]  [ 收藏]  [ 推荐给朋友]   [ 本帖文本页]

论坛跳转:
     
标题: [原创] 交换机访问控制  ( 查看:257  回复:5 )   
 
wccycl
技术员  点击可查看详细


帖子 95
精华 0
无忧币 1786
积分 267
阅读权限 30
注册日期 2007-9-6
最后登录 2008-7-3 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2007-9-26 14:56   标题:交换机访问控制
上一帖 |
通过本实验了解CISCO交换机的验证方法,防止非法用户访问交换机


初始配置
Switch
Conf t
Int f 0/1
No sw
Ip ad 10.1.1.2 255.255.255.0
End


Router
Conf t
Int e 0
Ip ad 10.1.1.1 255.255.255.0
No shut


Server IP address 10.1.2.1/24
测试
sw1#ping 10.1.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.1.1.1, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 12/52/116 ms

1,  在Router做TELNET 命令,访问Switch

Switch
Conf t
No service password-recovey
Enable secret ccie
Line vty 0 15
Login
Password ccie
End
在Router上校验
R1#telnet 10.1.1.2
Trying 10.1.1.2 ... Open


User Access Verification

Password:  被隐藏
sw1>en
Password:  被隐藏
sw1#           进入交换机特权模式
sw1#quit

[Connection to 10.1.1.2 closed by foreign host]
R1#           回到Router


2,  配置username和password对
这个配置使username 和password存储在本地交换机中,在switch上配置
Conf t
Username cisco password ccie
Line vty 0 15
Login local
End
在Router上校验
R1#telnet 10.1.1.2
Trying 10.1.1.2 ... Open


User Access Verification

Username: cisco
Password:  被隐藏
sw1>en
Password:  被隐藏
sw1#quit

[Connection to 10.1.1.2 closed by foreign host]
R1#


3,  配置多种特权等级
在交换机上配置用户,并对用户单独进行授权
Conf t
Username cisco privilege 2 password 0 ccie
在Router上校验
R1#telnet 10.1.1.2
Trying 10.1.1.2 ... Open


User Access Verification

Username: cisco
Password:
sw1#conf t
       ^
% Invalid input detected at '^' marker.
为什么会出错呢?因为我们没有对此用户的访问进行授权,现在交换机上进一步配置
Privilege exec level 2 conf t
Privilege configure level 2 interface
Privilege interface level 2 no switchport
Privilege interface level 2 ip address
Privilege interface level 2 no shut
在Router上校验
sw1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
sw1(config)#int f 0/2
sw1(config-if)#no sw
sw1(config-if)#ip ad 10.1.2.2 255.255.255.0
sw1(config-if)#shut
sw1(config-if)#no shut
sw1(config-if)#^Z
sw1#quit

[Connection to 10.1.1.2 closed by foreign host]
R1#


4,  在交换机上配置本地Authentication和Authorization服务,在本地交换机上AAA验证
Conf t
Aaa new-model
Aaa authentication login default local
Aaa authorization exec default local
Aaa authorization network default local
Username cisco password ccie

在Router上校验
Username: cisco
Password:

sw1>en
Password:
sw1#config t
Enter configuration commands, one per line.  End with CNTL/Z.
sw1(config)#^Z
sw1#quit

[Connection to 10.1.1.2 closed by foreign host]
R1#



下面来讨论TACACS+ SERVER和RADIUS SERVER的验证授权和统计。
1,  配置TACACS+ SERVER
Conf t
Tacacs-server host 10.1.2.1
Aaa new-model
Aaa group server tacacs+ group cisco
Server 10.1.2.1
Exit

2,  配置TACACS+登录验证
aaa authentication login default group tacacs+
Line vty 0 15
Login authentication default
exit

3,  配置TACACS+的EXEC访问和network授权
aaa authorization exec defaut group tacacs+
aaa authorization network defaut group tacacs+

4,  配置TACACS+的统计
Aaa accounting network default start-stop group tacacs+
Aaa accounting exec default start-stop group tacacs+




1,  配置RADIUS SERVER
Conf t
Radius-server host 10.1.2.1
Aaa new-model
Aaa group server radius group cisco
Server 10.1.2.1
Exit

2,  配置RADIUS登录验证
Aaa authentication login default group radius
Line vtp 0 15
Login authentication default
Exit

3,配置RADIUS的EXEC访问和network授权
Aaa authorization network default group radius
Aaa authorization exec default group radius

3,  配置RADIUS的统计
Aaa accounting network default start-stop group radius
Aaa accounting exec default start-stop group radius

4,  配置RADIUS服务器
Radius-server key ccie
Redius-server retransmit 3
Radius-server tiomout 60
Radius-server deadtime 10




网络工程师到底该不该去考CCIE认证?
2007-9-26 14:561楼
[ 顶部 ]
 
wxr__2008
新新人类  点击可查看详细



十二生肖之鼠   天蝎座   行业勋章   技术勋章   诚信兄弟  
帖子 26
精华 0
无忧币 33
积分 26
阅读权限 20
注册日期 2007-9-11
最后登录 2007-9-26 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2007-9-26 17:07 
......



网络工程师到底该不该去考CCIE认证?
2007-9-26 17:072楼
[ 顶部 ]
 
qaz555
助理工程师  点击可查看详细



帖子 2426
精华 0
无忧币 1
积分 2485
阅读权限 40
注册日期 2007-3-17
最后登录 2008-7-4 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2007-9-26 22:21 
dd



网络工程师到底该不该去考CCIE认证?
2007-9-26 22:213楼
[ 顶部 ]
 
gaofei21cn
新新人类  点击可查看详细



帖子 139
精华 0
无忧币 1
积分 151
阅读权限 20
注册日期 2007-8-12
最后登录 2008-7-6 离线

[查看资料]  [发短消息]  [Blog
       
发表于:2007-9-26 22:42 
好东西!!!!



网络工程师到底该不该去考CCIE认证?
2007-9-26 22:424楼
[ 顶部 ]
 
cnpfidc
技术员  点击可查看详细


帖子 518
精华 0
无忧币 1065
积分 542
阅读权限 30
注册日期 2007-8-9
最后登录 2008-7-1 离线

[查看资料]  [发短消息]  [Blog
  QQ       
发表于:2007-9-26 23:08 
不好意思,没看完..没心情看了..!~



网络工程师到底该不该去考CCIE认证?
2007-9-26 23:085楼
[ 顶部 ]
 
zf2008
新新人类  点击可查看详细



帖子 3
精华 0
无忧币 13
积分 3
阅读权限 20
注册日期 2007-9-28
最后登录 2007-9-28 离线

[查看资料]  [发短消息]  [Blog
  QQ       
发表于:2007-9-28 10:51 




网络工程师到底该不该去考CCIE认证?
2007-9-28 10:516楼
[ 顶部 ]
     
论坛跳转:  

| | |

| | |

| | |

标记已读 · 删除论坛Cookies · 文本版 · WAP
 
| 诚征版主 | 版主堂 | 意见建议 | 大史记 | 论坛地图
Copyright©2005-2008 51CTO.COM  Powered by Discuz!
本论坛言论纯属发布者个人意见,不代表51CTO网站立场!如有疑义,请与管理员联系。
京ICP备05051492号