天天看点

H3C、Huawei、Cisco网络设备AAA TACACS认证配置白皮书

TACACS技术白皮书

摘要:TACACS是实现AAA功能的一种安全协议,主要是通过TACACS客户端与TACACS服务器通信来实现多种用户的AAA功能。

HWTACACS采用TCP协议承载报文,TCP端口号是49。

  1. H3C

 hwtacacs scheme device-tacacs                        //配置radius scheme

 primary authentication xxx.xxx.xxx.xxx                   //认证服务器地址

 primary authorization xxx.xxx.xxx.xxx                     //授权服务器地址

 key authentication cipher ************           //认证配置密钥

 key authorization cipher ************           //授权配置密钥

 key accounting cipher ************             //授权配置密钥

 user-name-format without-domain            //配置不携带域名格式

 nas-ip 172.xxx.xxx.xxx                                //发送源地址(SW-MGMT-IP)

 domain device-login                                         //配置设备登录hwtacacs

 authentication login hwtacacs-scheme device-tacacs local      //认证顺序为tacacs,本地

 authorization login hwtacacs-scheme device-tacacs local        //授权顺序为tacacs,本地

 accounting login hwtacacs-scheme device-tacacs none        //审计顺序为tacacs

 authorization command hwtacacs-scheme device-tacacs         //命令授权为tacacs

super password role network-admin hash “xx” //特权密码

command-privilege level 1 view shell display current-configuration

command-privilege level 1 view  shell display device manuinfo

 //配置级别1权限

domain default enable device-login    //配置默认域

  1. 华为

    配置HWTACACS认证服务器

Hwtacacs enable                             //开启Hwtacacs功能

hwtacacs-server template device-tacacs       //建立服务模板

配置HWTACACS认证服务器

hwtacacs-server authentication xxx.xxx.xxx.xxx

hwtacacs-server authorization xxx.xxx.xxx.xxx

hwtacacs-server accounting xxx.xxx.xxx.xxx

hwtacacs-server source-ip 172.xxx.xxx.xxx.xxx    //交换机管理地址

hwtacacs-server timer response-timeout 2

配置HWTACACS服务器密钥

hwtacacs-server shared-key cipher ************

配置认证方案,配置认证方案hwtacacs,认证模式为先进行HWTACACS认证,后进行本地认证

aaa

authentication-scheme hwtacacs

authentication-mode hwtacacs local

配置授权方案,配置授权方案hwtacacs1,授权模式为先进行HWTACACS授权,后进行本地授权

authorization-scheme hwtacacs1

 authorization-mode  hwtacacs local

 authorization-cmd 15 hwtacacs local

配置计费方案,配置计费方案hwtacacs1,计费模式为先进行HWTACACS

accounting-scheme hwtacacs1

accounting-mode hwtacacs

accounting start-fail online

accounting interim-fail online

配置hwtacacs域

domain hwtacacs

authentication-scheme hwtacacs

accounting-scheme hwtacacs1

authorization-scheme hwtacacs1

hwtacacs-server device-tacacs

配置全局默认管理域

domain hwtacacs admin

远程登入授权

user-interface vty 0 4                   

authentication-mode aaa

只读账号登入授权

command-privilege level 1 view system display current-configuration

command-privilege level 1 view shell display device manufacture-info

command-privilege level 1 view shell display logbuffer

  1. Cisco

    配置AAA server 和key

aaa new-model

tacacs-server host xxx.xxx.xxx.xxx

tacacs-server key ************

或者(15.2(2)E3)

 tacacs server tacacs-server

 address ipv4 xxx.xxx.xxx.xxx

 key ************

配置认证方式(代表tacacs+ server失效后.使用本地认证)

aaa authentication login default group tacacs+ local   

 配置授权

aaa authorization exec default group tacacs+  local

aaa authorization commands 15 default group tacacs+ local

配置用户行为审计

  aaa accounting commands 15 default start-stop  group tacacs+

  aaa accounting exec default start-stop group tacacs+

  aaa accounting connection default start-stop group tacacs+

privilege exec level 1 show startup-config

  privilege exec level 1 show logging

//配置级别1权限

 认证授权

 line vty 0 4

login authentication default

authorization exec default

accounting connection default

accounting exec default

配置认证源vlan

ip tacacs source-interface Vlan xx