思科防火墙aaa
- 格式:pdf
- 大小:108.92 KB
- 文档页数:13
如何在Cisco设备上来配置AAA的认证?实验设备:cisco 3640路由器1台,PC一台,Console线缆一根,交叉线一根实验拓扑:实验过程:第一步:通过console线缆,使用超级终端或者SecureCRT登录路由器,完成基本配置,同时将交叉线连接到路由器E1/0,t在PC的接口上配置IP为192.168.10.1,掩码255.255.255.0 Router>enableRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#no ip domain-lookupRouter(config)#line console 0Router(config-line)#no exec-tRouter(config-line)#logg syn3640(config)#host R3640R3640(config)#int e1/0R3640(config-if)#ip add 192.168.10.3 255.255.255.0R3640(config-if)#no shR3640(config-if)#end*Mar 1 00:02:02.499: %SYS-5-CONFIG_I: Configured from console by consoleR3640#ping 192.168*Mar 1 00:02:03.659: %LINK-3-UPDOWN: Interface Ethernet1/0, changed state to up *Mar 1 00:02:04.659: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet1/0, changed state to upR3640#ping 192.168.10.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.10.1, timeout is 2 seconds:.Success rate is 80 percent (4/5), round-trip min/avg/max = 12/32/44 ms第二步:启用AAA,并配置登录验证为localR3640#conf tEnter configuration commands, one per line. End with CNTL/Z.R3640(config)#aaa ?new-model Enable NEW access control commands and functions.(Disables OLDcommands.)R3640(config)#aaa new-model全局启用AAA功能R3640(config)#aaa authentication login ?当用户登录时启用AAA认证功能,并且定义认证时调用的名字是默认的”default”,还是自己随便定义1个WORD Named authentication list.default The default authentication list.R3640(config)#aaa authentication login default ?指定用哪种认证方式 enable Use enable password for authentication. 使用特权密码group Use Server-group 使用Radius或者Tacacs+协议krb5 Use Kerberos 5 authentication. 使用Kerberoskrb5-telnet Allow logins only if already authenticated via Kerberos VTelnet.line Use line password for authentication. 使用线路认证方式 local Use local username authentication.使用本地认证方式,需配置用户名和密码local-case Use case-sensitive local username authentication.none NO authentication. 不做认证配置当用户登录设备时,使用aaa本地登录认证方式,认证调用的名字为default,认证方式为localR3640(config)#aaa authentication login default local配置本地登录时,使用的用户名和密码。
思科网络设备3A认证的开启及命名3A认证的配制方法一.3A认证概述在Cisco设备中,许多接口,许多地方,为了安全,都需要开启认证服务,比如我们通常配置的console下的密码,进入Privileged EXEC模式的enable密码,VTY线路下的密码,以及其它二层接口的认证密码等等。
这些密码配置在哪里,那里就开启了相应的认证服务。
并且这些认证服务方式是单一的,也没有备份认证方式,更重要的是,这些密码只能读取本地,却不可以通过读取远程服务器的认证方式来给自己提供认证服务。
要想将一个接口的认证方式调用到另外一个接口,或者让某接口使用远程服务器的认证方式,那就需要AAA中的认证来实现。
AAA中的认证可以给设备提供更多的认证方式,AAA认证就相当于一个装有认证方式的容器一样,里面可以有多个认证方式,当这个容器被安装在某个接口,那么这个接口也就拥有了容器中所有的认证方式。
而几乎所有的认证方式都可以被放入这个容器中,包含远程服务器的认证方式。
二.常见的3A认证配置方法(1)tacacs服务器和密码的宣告通常我们使用在全局模式下宣告tacacs服务器及密码的方式进行3A认证的配置,配置命令如图1所示。
图1 全局下tacacs服务器及密码的宣告方法在宣告tacacs服务器时,为了3A认证的冗余性,我们可以在全局模式下同时宣告多个tacacs服务器地址。
配置了多个tacacs服务器地址后,在进行3A认证时,设备会根据tacacs服务器配置的先后顺序逐一进行认证,直到找到一台可用的tacacs服务器,3A认证成功为止。
如图2。
图2 配置多个tacacs服务器这种宣告方式有一个缺陷,虽然我们可以同时宣告多个tacacs服务器,但是却只能宣告一个密码,也就是说用来进行冗余处理的tacacs服务器都必须要配置一样的认证密码,这样不利于网络设备的安全管理。
为了解决这一问题,我们可以将tacacs服务器与密码同时进行宣告,如图3.图3 tacacs服务器与密码同时宣告这种宣告方式解决了全局模式下只能宣告一个密码的问题,并且这种方式同样也可以同时宣告多条,和传统的宣告方式一样,这种新的宣告方式也会根据先后顺序进行逐条的调用。
AAA配置实例+注解cisco上配置AAA,AAA是指用使用Authentication、Authorization、Accounting三种功能对要管理交换机的用户做控制。
Authentication(认证):对用户的身份进行认证,决定是否允许此用户访问网络设备。
Authorization(授权):针对用户的不同身份,分配不同的权限,限制每个用户的操作Accounting(计费):对每个用户的操作进行审计和计费我们一般使用TACACS+、RADIUS协议来做cisco设备的AAA。
RADIUS是标准的协议,很多厂商都支持。
TACACS+是cisco私有的协议,私有意味只有cisco可以使用,TACACS+增加了一些额外的功能。
当用户的身份被认证服务器确认后,用户在能管理交换机或者才能访问网络;在访问设备的时候,我们可以针对这个用户授权,限制用户的行为;最后我们将记录用在设备的进行的操作。
在认证的时候,有一下这些方法:1.在交换机本地进行用户名和密码的设定,也就是在用户登录交换机的收,交换机会对比自己的本地数据库,查看要登录的用户所使用的用户名和密码的正确性。
2.使用一台或多台(组)外部RADIUS服务器认证3.使用一台或多台(组)外部TACACS+服务器认证用一个配置实例,说明交换机上操作username root secret cisco#在交换机本地设置一个用户,用户名是root,密码是cisco。
aaa new-model#在交换机上激活AAAaaa authentication login default group tacacs+local#设置一个登录交换机是认证的顺序,先到tacacs+服务器认证,如果tacacs+服务器出现了故障,不能使用tacacs+认证,我们可以使用交换机的本地数据库认证,也就是用户名root密码ciscoaaa authorization exec default group tacacs+if-authenticated#如果用户通过了认证,那么用户就能获得服务器的允许,运行交换机的EXEC对话aaa authorization commands15default group tacacs+local#在任何权限在使用交换机命令式都要得到tacacs+服务器许可,如果tacacs+出现故障,则要通过本地数据库许可aaa accounting exec default start-stop group tacacs+#记录用户进去EXEC对话的认证信息、用户的地址和对话的开始时间持续时间,记录的过程是从开始到结束aaa accounting commands1default start-stop group tacacs+ aaa accounting commands15default start-stop group tacacs+!tacacs-server host192.168.1.1#定义tacacs服务器地址是192.168.1.1tacacs-server key cisco#定义交换机和tacacs服务器之间通信中使用的key为ciscoline vty04login authentication defaultauthorization exec defaultaccounting exec default最近在搭建公司的ACS,总结了一些经验写在这里。
思科Asa & pix 防火墙命令详解配置PIX防火墙有6个基本命令:nameif,interface,ip address,nat,global,route,static.1. 配置防火墙接口的名字,并指定安全级别(nameif)。
Pix525(config)#nameif ethernet0 outside security0Pix525(config)#nameif ethernet1 inside security100Pix525(config)#nameif dmz security502. 配置以太口参数(interface)Pix525(config)#interface ethernet0 autoPix525(config)#interface ethernet1 100fullPix525(config)#interface ethernet1 100full shutdown3. 配置内外网卡的IP地址(ip address)Pix525(config)#ip address outside 61.144.51.42 255.255.255.248Pix525(config)#ip address inside 192.168.0.1 255.255.255.04. 指定要进行转换的内部地址(nat)nat命令配置语法:nat (if_name) nat_id local_ip [netmark]if_name)表示内网接口名字,例如inside;Nat_id用来标识全局地址池,使它与其相应的global命令相匹配;若为0表示不进行nat转换。
例1.Pix525(config)#nat (inside) 1 0 05. 指定外部地址范围(global)Global命令的配置语法:global (if_name) nat_id ip_address-ip_address [netmark global_mask]例1.Pix525(config)#global (outside) 1 61.144.51.42-61.144.51.486. 设置指向内网和外网的静态路由(route)route命令配置语法:route if_name 0 0 gateway_ip [metric]例1.Pix525(config)#route inside 10.1.1.0 255.255.255.0 172.16.0.1 1Pix525(config)#route inside 10.2.0.0 255.255.0.0 172.16.0.1 17. 配置静态IP地址翻译(static)static命令配置语法:static (internal_if_name,external_if_name) outside_ip_address inside_ip_address例1.Pix525(config)#static (inside, outside) 61.144.51.62 192.168.0.88. 管道命令(conduit)conduit命令配置语法:conduit permit | deny global_ip port[-port] protocol foreign_ip [netmask] permit | deny :允许| 拒绝访问例1. Pix525(config)#conduit permit tcp host 61.144.51.89 eq www any9. 访问控制列表ACL例:PIX525(config)#access-list 100 permit tcp any host 61.144.51.62 eq wwwPIX525(config)#access-list 100 deny tcp any anyPIX525(config)#access-group 100 in interface outside例1:static (inside,outside) 59.61.77.202 192.168.1.2 netmask 255.255.255.255 0 0 //定义内部主机192.168.1.2对外ip为59.61.77.20210. 配置fixup协议fixup命令作用是启用,禁止,改变一个服务或协议通过pix防火墙,由fixup命令指定的端口是pix防火墙要侦听的服务。
增加一台服务器具体要求。
新增一台服务器地址:10.165.127.15/255.255.255.128。
需要nat 转换成公网地址16.152.91.223 映射出去,并对外开通这台服务器的80端口。
在对外pix525上面增加如下:access-list acl_out permit tcp any host 16.52.91.223 eq www //开放外网对新服务器80端口static (inside,outside) 16.152.91.223 10.165.127.15 netmask 255.255.255.255 0 0 ////外高桥新服务器地址转换16.152.91.223可是为什么转换后,不能访问16.52.91.223的网页,但确可以ping通16.52.91.223,但是访问10.165.127.15的主页是正常的??具体配置如下:pix-525> enablePassword: *****pix-525# sh run: Saved:PIX Version 6.3(5)interface ethernet0 100fullinterface ethernet1 100fullnameif ethernet0 outside security0nameif ethernet1 inside security100enable password FVHQD7n.FuCW78fS level 7 encryptedenable password 2KFQnbNIdI.2KYOU encryptedpasswd 2KFQnbNIdI.2KYOU encryptedhostname wgqpix-525fixup protocol dns maximum-length 512fixup protocol ftp 21fixup protocol h323 h225 1720fixup protocol h323 ras 1718-1719fixup protocol http 80fixup protocol rsh 514fixup protocol rtsp 554fixup protocol sip 5060fixup protocol sip udp 5060fixup protocol skinny 2000fixup protocol smtp 25fixup protocol sqlnet 1521fixup protocol tftp 69namesaccess-list acl_out permit tcp any host 16.152.91.221 eq wwwaccess-list acl_out permit icmp any anyaccess-list acl_out permit tcp any host 16.152.91.220 eq httpsaccess-list acl_out permit tcp any host 16.152.91.223 eq wwwaccess-list outbound permit icmp any anyaccess-list outbound permit ip any anypager lines 24mtu outside 1500mtu inside 1500ip address outside 16.152.91.222 255.255.255.128ip address inside 10.165.127.254 255.255.255.252ip audit info action alarmip audit attack action alarmno failoverfailover timeout 0:00:00failover poll 15no failover ip address outsideno failover ip address insideno pdm history enablearp timeout 14400static (inside,outside) 16.152.91.221 10.165.127.11 netmask 255.255.255.255 0 0 static (inside,outside) 16.152.91.220 10.165.127.23 netmask 255.255.255.255 0 0 static (inside,outside) 16.152.91.223 10.165.127.15 netmask 255.255.255.255 0 0 access-group acl_out in interface outsideaccess-group outbound in interface insideroute outside 0.0.0.0 0.0.0.0 16.152.91.129 1route inside 10.165.0.0 255.255.0.0 10.165.127.253 1timeout xlate 3:00:00timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 rpc 0:10:00 h225 1:00:00 timeout h323 0:05:00 mgcp 0:05:00 sip 0:30:00 sip_media 0:02:00timeout sip-disconnect 0:02:00 sip-invite 0:03:00timeout uauth 0:05:00 absoluteaaa-server TACACS+ protocol tacacs+aaa-server TACACS+ max-failed-attempts 3aaa-server TACACS+ deadtime 10aaa-server RADIUS protocol radiusaaa-server RADIUS max-failed-attempts 3aaa-server RADIUS deadtime 10aaa-server LOCAL protocol localhttp server enableno snmp-server locationno snmp-server contactsnmp-server community publicno snmp-server enable trapsfloodguard enabletelnet 10.165.6.225 255.255.255.255 insidetelnet 10.165.127.12 255.255.255.255 insidetelnet 10.165.127.250 255.255.255.255 insidetelnet 10.165.6.15 255.255.255.255 insidetelnet 10.165.6.16 255.255.255.255 insidetelnet timeout 5ssh timeout 5console timeout 0username admin password iuQeTKNaNbruxBKd encrypted privilege 2terminal width 80Cryptochecksum:b2e1195d144f48f01fe66606cd31d0f2: endwgqpix-525#最佳答案( 回答者: xintao800 )PIX防火墙提供4种管理访问模式:²非特权模式。
cisco AAA认证服务器及设备配置AAA代表Authentication、Authorization、Accounting,意为认证、授权、记帐,其主要目的是管理哪些用户可以访问服务器,具有访问权的用户可以得到哪些服务,如何对正在使用网络资源的用户进行记帐。
1、认证:验证用户是否可以获得访问权限——“你是谁?”2、授权:授权用户可以使用哪些资源——“你能干什么?”3、记帐:记录用户使用网络资源的情况——“你干了些什么?”好的,简单的了解理论知识后,接下来我们还是以实验的方式来进行讲解:为网络提供AAA服务的,主要有TACACS+和RADIUS协议,我们主要介绍是TACACS+协议,因为它运行在TCP协议基础之上,更适合大型网络,特别是融合型网络一、实验拓扑介绍该实验主要完成R1路由通过ACS服务器实现AAA认证,包括验证、授权和记帐,同时还包括PPP验证和计时通过cisco ACS实验二、安装cisco ACS1、硬软件要求硬件:Pentium IV 处理器, 1.8 GHz 或者更高操作系统:Windows 2000 ServerWindows 2000 Advanced Server (Service Pack 4)Windows Server 2003,Enterprise Edition or StandardEdition (Service Pack 1)内存:最小1GB虚拟内存:最小1GB硬盘空间:最小1GB可用空间,实际大小根据日志文件的增长,复制和备份的需求而定。
浏览器:Microsoft Internet Explorer 6 或者更高版本JAVA运行环境:Sun JRE 1.4.2_04 或更高版本网络要求:在CISCO IOS 设备上为了全面的支持TACACS+ 和RADIUS,AAA 客户端必须运行Cisco IOS 11.1 或者更高的版本。
非CISCO IOS 设备上必须用TACACS+,RADIUS或者两者一起配置。
AAA服务器解决方案一、AAA概述1. 什么是AAAAAA是Authentication,Authorization and Accounting(认证、授权和计费)的简称,它提供了一个用来对认证、授权和计费这三种安全功能进行配置的一致性框架,实际上是对网络安全的一种管理。
这里的网络安全主要是指访问控制,包括:哪些用户可以访问网络服务器?具有访问权的用户可以得到哪些服务?如何对正在使用网络资源的用户进行计费?针对以上问题,AAA必须提供下列服务:认证:验证用户是否可获得访问权。
授权:授权用户可使用哪些服务。
计费:记录用户使用网络资源的情况。
2. AAA的优点由于AAA一般采用客户/服务器结构:客户端运行于被管理的资源侧,服务器上集中存放用户信息,因此,AAA框架具有如下的优点:具有良好的可扩展性可以使用标准化的认证方法容易控制,便于用户信息的集中管理可以使用多重备用系统来提升整个框架的安全系数3、 RADIUS协议概述如前所述,AAA是一种管理框架,因此,它可以用多种协议来实现。
在实践中,人们最常使用RADIUS协议来实现AAA。
3.1什么是RADIUSRADIUS是Remote Authentication Dial-In User Service(远程认证拨号用户服务)的简称,它是一种分布式的、客户机/服务器结构的信息交互协议,能保护网络不受未授权访问的干扰,常被应用在既要求较高安全性、又要求维持远程用户访问的各种网络环境中(例如,它常被应用来管理使用串口和调制解调器的大量分散拨号用户)。
RADIUS系统是NAS(Network Access Server,网络接入服务器)系统的重要辅助部分。
当RADIUS系统启动后,如果用户想要通过与NAS(PSTN环境下的拨号接入服务器或以太网环境下带接入功能的以太网交换机)建立连接从而获得访问其它网络的权利或取得使用某些网络资源的权利时,NAS,也就是RADIUS客户端将把用户的认证、授权和计费请求传递给RADIUS服务器。
CISCO交换机AAA配置一、RADIUS相关配置【必要命令】全局模式switch(config)# aaa new-model注:启用AAA认证switch(config)# aaa authentication dot1x default group radius local注:启用AAA通过RADIUS服务器做认证switch(config)# aaa authorization network default group radius local注:启用AAA通过RADIUS服务器做授权switch(config)# dot1x system-auth-control注:开启全局dot1x控制switch(config)# dot1x guest-vlan supplicant注:允许dot1x验证失败后加入guestvlanswitch(config)# radius-server host 10.134.1.207 auth-port 1812 acct-port 1813 key 123456注:指定NPS服务器的ip地址、认证和授权端口、以及通信密码switch(config)# radius-server vsa send authentication注:允许交换机识别和使用IETF规定的VSA值,用于接受NPS 分配vlanswitch(config)# ip radius source-interface vlan 2注:当交换机有多个IP时,只允许该vlan段的IP作为发送给RADIUS服务器的IP地址端口模式switch(config)# interface FastEthernet0/10注:进入端口模式(批量端口配置命令:interface range FastEthernet0/1 - 48)switch(config-if)# switchport mode access注:端口配置dot1x前必须设置为access模式switch(config-if)# mab(IOS 12.2之前的版本命令:dot1x mac-auth-bypass)注:当dot1x验证超时后会以mac为用户名密码发起验证switch(config-if)# dot1x pae authenticator注:设置交换机的pae模式switch(config-if)# authentication port-control auto(IOS 12.2之前的版本命令:dot1x port-control auto)注:设置dot1x端口控制方式,auto为验证授权switch(config-if)# authentication event no-response action authorize vlan 3(IOS 12.2之前的版本命令:dot1x guest-vlan 3)注:NPS验证失败时放置的vlan【可选命令】全局模式switch(config)# radius-server retransmit 2注:交换机向RADIUS服务器发送报文的重传次数switch(config)# radius-server timeout 2注:交换机向RADIUS服务器发送报文的超时时间端口模式switch(config-if)# dot1x timeout tx-period 2注:交换机向dot1x端口定期多长时间发报文switch(config-if)# dot1x timeout supp-timeout 2注:交换机向客户端发送报文,客户端未回应,多长时间后重发switch(config-if)# dot1x timeout server-timeout 2注:交换机向RADIUS服务器发送报文,服务器未回应,多长时间后重发二、其他【必要命令】SNMP设置switch(config)# snmp-server community skylark RW注:用于管理交换机,接收交换机相关信息DHCP中继代理(在网关交换机上配置)switch(config)# interface vlan 2注:进入vlan接口switch(config-if)# ip helper-address 10.134.1.207注:设置DHCP地址,使不同vlan的客户端可以获取IP地址【可选命令】DHCP SNOOPINGswitch(config)# ip dhcp snooping注:开启全局DHCP SNOOPYING功能switch(config)# ip dhcp snooping vlan 2注:指定DHCP SNOOPYING范围switch(config)# interface g0/1注:进入接口(配置级联端口和连接DHCP服务器的端口为信任端口)switch(config-if)# ip dhcp snooping trust注:设置该端口为信任端口,默认其它未设置端口则为不信任端口,丢弃不信任的DHCP报文IP SOURCE GUARDswitch(config)# interface vlan 2注:进入vlan接口switch(config-if)# ip verify source port-security注:动态绑定DHCP-SNOOPING表项,过滤掉其它数据(无port-security则只绑定ip,有port-security则是绑定ip+mac)相关命令show ip dhcp snooping bindingSTP生成树Switch(config-if)# spanning-tree portfast注:生成树的端口快速转发,更加快速从DHCP获取IP地址端口错误检测switch(config)# errdisable recovery cause all注:防止交换机端口因异常被关闭,恢复其正常状态switch(config)# errdisable recovery interval 30注:设置交换机端口故障关闭时间,过后关闭的端口自动打开。
思科交换机安全配置(包括A A A、端口安全、A R P安全、D H C P侦听、日志审计流量限制)-标准化文件发布号:(9456-EUATWK-MWUB-WUNN-INNUL-DDQTY-KII网络拓扑图如下:根据图示连接设备。
在本次试验中,具体端口情况如上图数字标出。
核心交换机(core )设置为s1或者SW1,汇聚层交换机(access)设置为s2或者SW2。
IP 地址分配:Router:e0: 192.168.1.1Core:f0/1: 192.168.1.2Svi接口:Core vlan10: 172.16.10.254Vlan20: 172.16.20.254Vlan30: 172.16.30.254Access vlan10: 172.16.10.253Vlan20: 172.16.20.253Vlan30: 172.16.30.253服务器IP地址:192.168.30.1Office区域网段地址:PC1:192.168.10.1PC2:192.168.10.2路由器清空配置命令:enerase startup-configReload交换机清空配置命令:enerase startup-configdelete vlan.datReload加速命令:enconf tno ip domain lookupline con 0exec-timeout 0 0logging synhostname一、OFFICE 区域地址静态分配,防止 OFFICE 网络发生 ARP 攻击,不允许OFFICE 网段 PC 互访;STUDENTS 区域主机输入正确的学号和密码后接入网络,自动获取地址,阻止STUDENTS网段地址发生ARP攻击;1、基本配置SW1的配置:SW1(config)#vtp domain cisco //SW1配置vtp,模式为server,SW2模式为clientSW1(config)#vtp password sovandSW1(config)#vtp mode serverSW1(config)#vlan 10SW1(config)#int range f0/3,f0/4 //链路捆绑SW1(config-if-range)#Channel-protocol pagpSW1(config-if-range)#Channel-group 10 mode onSW1(config)#int port-channel 10 //链路设置为trunk模式,封装802.1q协议,三层交换机默认没有封装该协议SW1(config-if)#switchport trunk encapsulation dot1qSW1(config-if)#switchport mode trunkSW2配置:SW2(config)#vtp domain ciscoSW2(config)#vtp password sovandSW2(config)#vtp mode clientSW2(config)#int range f0/3,f0/4SW2(config-if-range)#Channel-protocol pagpSW2(config-if-range)#Channel-group 10 mode onCreating a port-channel interface Port-channel 10SW2(config)#int port-channel 10SW2(config-if)#switchport trunk encapsulation dot1qSW2(config-if)#switchport mode trunkSW2(config)#int f0/1 //把f0/1,f0/2划入vlan10SW2(config-if)#switchport mode accessSW2(config-if)#switchport access vlan 10SW2(config-if)#int f0/2SW2(config-if)#switchport mode accessSW2(config-if)#switchport access vlan 102、vlan aclOffice区域禁止PC机互访:使用show int e0/0命令查看mac地址SW2(config)#mac access-list extended macaclSW2(config-ext-macl)#permit host 0007.8562.9de0 host 0007.8562.9c20 //要禁止双向通信SW2(config-ext-macl)#permit host 0007.8562.9c20 host 0007.8562.9de0SW2(config)#vlan access-map vmap 10 //禁止pc间的通信SW2(config-access-map)#match mac add macaclSW2(config-access-map)#action dropSW2(config)#vlan access-map vmap 20 //对其他数据放行,不然pc机无法ping 通svi口、网关SW2(config-access-map)#action forwardSW2(config)#vlan filter vmap vlan-list 10未使用VLAN ACL时pc1可以ping通pc2,如下图:使用VLAN ACL时pc1可以无法ping通pc2,如下图:3、Office区域静态配置ip地址时采用的ARP防护:配置如下:SW2(config)#ip arp inspection vlan 10SW2(config)#arp access-list arplistSW2(config-arp-nacl)#permit ip host 192.168.10.1 mac host 0007.8562.9de0 //ip地址与mac地址对应表SW2(config-arp-nacl)#permit ip host 192.168.10.2 mac host 0007.8562.9c20SW2(config-arp-nacl)#ip arp inspection filter arplist vlan 10SW2(config)#int port-channel 10SW2(config-if)#ip arp inspection trust注意:配置静态arp防护(用户主机静态配置地址,不是通过DHCP获取地址),需要新建ip与mac映射表,不然pc1无法ping通svi口4、OSPF与DHCP全网起OSPF协议,使pc1可以ping通路由器。