Securing Networks With Cisco Routers and Switches

aaa server(cisco secure access control server)

1.aaa是什么

authentication 识别用户

authorization 由一系列的属性限定用户能够有什么权限(av pair)

accounting 统计用户在什么时间、什么地方、做了什么.

1.网管登录流量

2.穿越流量

3.拨入流量

2.为什么要用3a

1.跟nas的数量(互联网接入点)

2.跟人数有关

3.跟人员变动的频率

可扩展性、标准化的协议、备份系统(method lists).

3.3a的基本拓扑

4.3a的基本协议client---nat---aaa

讲解基本拓扑图

三大类的协议client---nas

1.登录路由器

2.拨入路由器

3.穿越路由器

两大协议nas---aaa

radius

tacacas+

协议比较

tacacs+思科私有,radius业界标准,在做认证授权审计,radius的认证和授权是集成在一起做的.而tacacs+是单独来做的,没有关联的,而radius认证授权必须同时做,只有认证成功才能授权,协议不同,tacacs+通信协议tcp 49,radius使用udp两组端口号,一组是port authen/author 1645,port account 1646,ietf port authen/author 1812,port account 1813.chap认证,tacacs+使用双向认证,radius使用单向认证,tacacs+多协议支持,radius不支持ara,netbeui,tacacs+对通信的包是全加密的,radius只是对密码加密,tacacs+审计有限制,radius审计更强.

cisco的acs可以为路由器,交换机,pix所有的网络设备提供网络服务,这些网络设备就称为acs的client.可以集中化的管理和审计.可以允许网络管理员快速的管理账户,支持外部用户数据库,可以同时提供radius和tacacs+协议服务,支持其他的一些token server一次性密码.使用tacacs+或者radius之间思科安全acs和nas,允许认证使用windows 2000数据库和自己的数据库,支持pap,chap,和ms-chap认证到nas.

tacacs+支持访问列表,可以控制时间接入,ara(aptoken协议),级别授权.radius支持ietf radius,支持cisco radius 属性值.其他专有的radius.

密码协议支持

ascii/pap

chap

ms-chap

leap

eap-chap

eap-tls

arap

远程登录acs

http://192.168.1.241:2002

实验:

nas:

int e0/0

ip add 170.1.1.11 255.255.255.0

no sh

int lo0

ip add 1.1.1.1 255.255.255.0

line vty 0 4

login

password cisco

line vty 0 4

login local

username cisco password cisco

line vty 0 4

no login

aaa new-model

aaa authentication login FOR_CON none

line con 0

login authentication FOR_CON

aaa authenticaiton login FOR_VTY none(不适用任何密码和no login一个效果)

line vty 0 4

login authentication FOR_VTY

aaa authenticaiton login FOR_VTY line(使用线下密码认证)

aaa authentication login FOR_VTY local(使用本地账号密码认证)

aaa authentication login FOR_VTY local-case(使用本地账号密码认证区分大小写)

aaa authentication login FOR_VTY enable(使用enable密码作为认证)

aaa new-model

aaa authentication login FOR_CON none

lone con 0

login authenticaiton FOR_CON

aaa authentication login FOR_VTY line(如果line下没有密码,认证失败)

aaa authentication login FOR_VTY line none(先使用line密码认证,如果认证失败跳到没有密码,不是输入错误密码,而是line没有密码)

tacacs-server host 170.1.1.241 key cisco

aaa authenticaiton login FOR_VTY group tacacs+

radius-server host 170.1.1.241 key cisco

aaa authentication lgoin FOR_VTY group radius

line vty 0 4

no login authentication FOR_VTY

aaa authenticaiton login default group tacacs+(所有关于认证的地方全部使用default,没有调用别的名字的)

aaa authentication enable default none(enbale认证不认证)

aaa authentication enable default enable(使用enable密码作为enable密码)

aaa authentication enable default line(使用line的密码作为认证,如果line线下没有password那么永远进不了特权模式)

aaa authentication enbale default group tacacs+(没有在aaa服务器设置enable密码,就进不去)

aaa authentication enable default none

aaa authorization exec(级别授权) FOR_CON none(对con口不授权)

line con 0

authorizaiton exec FOR_CON

aaa authorizaiton exec FOR_VTY local(使用本地授权)

username admin privilege 15 password cisco(用户级别为15)

aaa authentication login FOR_VTY local

line vty 0 4

login authentication FOR_VTY

authorization exec FOR_VTY

aaa authentication login FOR_VTY group tacacs+

aaa authorization exec FOR_VTY group tacacs+

privilege exec level 10 conf t(在路由器授权10级用户使用conf t)

privilege configure all level 10 router(允许级别10的用户使用router所有命令)

aaa authorization commands(命令授权) 0 FOR_VTY group tacacs+(做命令授权要从高级别开始做,不然会出问题)

line vty 0 4

authorization commands 0 FOR_VTY

aaa authorzation commands 15 FOR_VTY group tacacs+line vty 0 4

authorzation commands 15 FOR_VTY

aaa authorzation config-commands

aaa accounting exec default start-stop group tacacs+(统计登录和退出时间)

aaa accounting commands 15 default start-stop group tacacs+(登录进来使用那些命令)

aaa accounting commands 1 default start-stop group tacacs+

aaa accounting commands 0 default start-stop group tacacs+

line vty 0 4

accounting commands 15 FOR_VTY(调用)

aaa accounting commands 10 default start-stop group tacacs+