自拍偷在线精品自拍偷,亚洲欧美中文日韩v在线观看不卡

詳談DHCP SNOOP等多方面的安全設(shè)置

網(wǎng)絡(luò) 網(wǎng)絡(luò)管理
文章中,我們針對交換機(jī)安全 802.1X、port-security、DHCP SNOOP、DAI、VACL、SPAN RSPAN等等方面進(jìn)行了分析和講解,希望對大家有用。

我們知道DHCP協(xié)議,管理網(wǎng)絡(luò)IP的協(xié)議。在其服務(wù)器的應(yīng)用中,我們也通常遇到有關(guān)的管理知識。那么對于網(wǎng)絡(luò)安全方面,DHCP有著更多值得注意的地方。那么今天我們就來講解一下交換機(jī)安全 802.1X、port-security、DHCP SNOOP、DAI、VACL、SPAN RSPAN的內(nèi)容。

交換機(jī)安全 802.1X、port-security、DHCP SNOOP、DAI、VACL、SPAN RSPAN
端口和MAC綁定:port-security
基于DHCP的端口和IP,MAC綁定:ip source guard
基于DHCP的防止ARP攻擊:DAI
防止DHCP攻擊:DHCP Snooping

cisco所有局域網(wǎng)緩解技術(shù)都在這里了!

常用的方式:

802.1X,端口認(rèn)證,dot1x,也稱為IBNS(注:IBNS包括port-security):基于身份的網(wǎng)絡(luò)安全; 很多名字,有些煩.當(dāng)流量來到某個(gè)端口,需要和ACS交互,認(rèn)證之后得到授權(quán),才可以訪問網(wǎng)絡(luò),前提是CLIENT必須支持802.1X方式,如安裝某個(gè)軟件

Extensible Authentication Protocol Over Lan(EAPOL)    使用這個(gè)協(xié)議來傳遞認(rèn)證授權(quán)信息

示例配置:

  1. Router#configure terminal  
  2. Router(config)#aaa new-model  
  3. Router(config)#aaa authentication dot1x default group radius  
  4. Switch(config)#radius-server host 10.200.200.1 auth-port 1633 key radkey  
  5. Router(config)#dot1x system-auth-control 起用DOT1X功能  
  6. Router(config)#interface fa0/0  
  7. Router(config-if)#dot1x port-control auto 

AUTO是常用的方式,正常的通過認(rèn)證和授權(quán)過程

強(qiáng)制授權(quán)方式:不通過認(rèn)證,總是可用狀態(tài)

強(qiáng)制不授權(quán)方式:實(shí)質(zhì)上類似關(guān)閉了該接口,總是不可用

可選配置:

  1. Switch(config)#interface fa0/3  
  2. Switch(config-if)#dot1x reauthentication  
  3. Switch(config-if)#dot1x timeout reauth-period 7200 

2小時(shí)后重新認(rèn)證

  1. Switch#dot1x re-authenticate interface fa0/3 

現(xiàn)在重新認(rèn)證,注意:如果會(huì)話已經(jīng)建立,此方式不斷開會(huì)話

  1. Switch#dot1x initialize interface fa0/3 

初始化認(rèn)證,此時(shí)斷開會(huì)話

  1. Switch(config)#interface fa0/3  
  2. Switch(config-if)#dot1x timeout quiet-period 45 

45秒之后才能發(fā)起下一次認(rèn)證請求

  1. Switch(config)#interface fa0/3  
  2. Switch(config-if)#dot1x timeout tx-period 90 默認(rèn)是30S  
  3. Switch(config-if)#dot1x max-req count 4 

客戶端需要輸入認(rèn)證信息,通過該端口應(yīng)答AAA服務(wù)器,如果交換機(jī)沒有收到用戶的這個(gè)信息,交換機(jī)發(fā)給客戶端的重傳信息,30S發(fā)一次,共4次

  1. Switch#configure terminal  
  2. Switch(config)#interface fastethernet0/3  
  3. Switch(config-if)#dot1x port-control auto  
  4. Switch(config-if)#dot1x host-mode multi-host 

默認(rèn)是一個(gè)主機(jī),當(dāng)使用多個(gè)主機(jī)模式,必須使用AUTO方式授權(quán),當(dāng)一個(gè)主機(jī)成功授權(quán),其他主機(jī)都可以訪問網(wǎng)絡(luò);

當(dāng)授權(quán)失敗,例如重認(rèn)證失敗或LOG OFF,所有主機(jī)都不可以使用該端口

  1. Switch#configure terminal  
  2. Switch(config)#dot1x guest-vlan supplicant  
  3. Switch(config)#interface fa0/3  
  4. Switch(config-if)#dot1x guest-vlan 2 

未得到授權(quán)的進(jìn)入VLAN2,提供了靈活性#p#

注意:

1、VLAN2必須是在本交換機(jī)激活的,計(jì)劃分配給游客使用;2?VLAN2信息不會(huì)被VTP傳遞出去

  1. Switch(config)#interface fa0/3  
  2. Switch(config-if)#dot1x default 

回到默認(rèn)設(shè)置

  1. show dot1x [all] | [interface interface-id] | [statistics interface interface-id] [{ | begin | exclude | include} expression]  
  2. Switch#sho dot1x all  
  3. Dot1x Info for interface FastEthernet0/3  
  4. ----------------------------------------------------  
  5. Supplicant MAC 0040.4513.075b  
  6. AuthSM State = AUTHENTICATED 
  7. BendSM State = IDLE 
  8. PortStatus = AUTHORIZED 
  9. MaxReq = 2 
  10. HostMode = Single 
  11. Port Control = Auto 
  12. QuietPeriod = 60 Seconds  
  13. Re-authentication = Enabled 
  14. ReAuthPeriod = 120 Seconds  
  15. ServerTimeout = 30 Seconds  
  16. SuppTimeout = 30 Seconds  
  17. TxPeriod = 30 Seconds  
  18. Guest-Vlan = 0debug dot1x {errors | events | packets | registry | state-machine | all} 

2、端口安全,解決CAM表溢出攻擊(有種MACOF的工具,每分鐘可以產(chǎn)生155000個(gè)MAC地址,去轟擊CAM表,從而使合法主機(jī)的要求都必須被FLOOD)

示例配置:

  1. Switch#configure terminal  
  2. Switch(config)#interface fastethernet0/0  
  3. Switch(config-if)#switchport mode access  
  4. Switch(config-if)#switchport port-security  
  5. Switch(config-if)#switchport port-security maximum 20 這里默認(rèn)是1  
  6. Switch(config-if)#switchport port-security mac-address sticky 

保存學(xué)習(xí)到的地址到RUN CONFIG文件中,避免手動(dòng)配置的麻煩,并省去動(dòng)態(tài)學(xué)習(xí)所消耗的資源

  1. switchport port-security violation {protect | restrict | shutdown} 

三個(gè)參數(shù)解釋:

保護(hù):當(dāng)達(dá)到某個(gè)設(shè)定的MAC數(shù)量,后來的未知MAC不再解析,直接丟棄,且不產(chǎn)生通知

限制:當(dāng)達(dá)到某個(gè)設(shè)定的MAC數(shù)量,后來的未知MAC不再解析,直接丟棄,產(chǎn)生通知,如SNMP TRAP?SYSLOG信息,并增加違反記數(shù);這里有個(gè)問題,惡意攻擊會(huì)產(chǎn)生大量的類似信息,給網(wǎng)絡(luò)帶來不利.

關(guān)閉:當(dāng)達(dá)到某個(gè)設(shè)定的MAC數(shù)量,后來的未知MAC不再解析,直接關(guān)閉該端口,除非手動(dòng)開啟,或改變端口安全策略

端口安全需要全部手動(dòng)配置,增加工作量,下面的兩種方式

DHCP SNOOP

如網(wǎng)吧的管理員使用DHCP分配地址的時(shí)候執(zhí)行IP和MAC地址的捆綁

  1. Switch#configure terminal  
  2. Switch(config)#ip dhcp snooping  
  3. Switch(config)#ip dhcp snooping vlan 34  
  4. Switch(config)#ip dhcp snooping information option  
  5. Switch(config)#interface fa0/0 連接DHCP服務(wù)器的接口  
  6. Switch(config-if)#ip dhcp snooping limit rate 70  
  7. Switch(config-if)#ip dhcp snooping trust  

指定該接口為信任接口,將獲得DHCP服務(wù)器所分配的地址,其他接口所發(fā)生的DHCP行為將被否決DAI動(dòng)態(tài)ARP審查,調(diào)用ACL和DHCP SNOOP的IP-TO-MAC數(shù)據(jù)庫

  1. Switch#configure terminal  
  2. Switch(config)#ip arp inspection filter這里調(diào)用ACL  

注意,只能調(diào)用ARP ACL,該ACL優(yōu)先與IP-TO-MAC表被審查,也就是說,即使有綁定項(xiàng)存在,如果被ARP-ACL拒絕,也不能通過

  1. Switch(config)#ip arp inspection vlan 34  
  2. Switch(config)#interface fa0/0  
  3. Switch(config-if)#ip arp inspection trust  

連接到DHCP服務(wù)器的接口,調(diào)用該接口上的DHCP SNOOP的IP-TO-MAC表,默認(rèn)連接到主機(jī)的接口都是不信任的接口

  1. Switch(config-if)#ip arp inspection limit rate 20 burst interval 2 

不信任接口限制為每秒14個(gè)ARP請求,信任接口默認(rèn)不受限制,這里修改為每秒20

  1. Switch(config-if)#exit  
  2. Switch(config)#ip arp inspection log-buffer entries 64 記錄拒絕信息64條 

注意:DHCP SNOOP只提供IP-TO-MAC綁定表,本身不參與流量策略,只是防止DHCP欺騙,而對任何IP和MAC欺騙

是沒有能力阻止的,但是它提供這樣一張表給DAI調(diào)用,以防止MAC欺騙

  1. ip arp-inspection 僅僅對違規(guī)的ARP包進(jìn)行過濾,不對IP包和其他包起作用  
  2. ip source verify 會(huì)對綁定接口的IP或者IP+MAC進(jìn)行限制 

3、VACL

  1. Configuring VACLs for Catalyst 6500 Traffic Capture  
  2. Router(Config)# access-list 110 permit tcp any 172.12.31.0.0.0.0.255 eq 80  
  3. Router(config)# vlan access-map my_map  
  4. Router(config-access-map)# match ip address 110  
  5. Router(config-access-map)# action forward capture  
  6. Router(config)# vlan filter my_map 10-12,15  
  7. Router(config)# interface fa 5/7  
  8. Router(config-if) switchport capture allowed vlan 10-12, 15 

4、SPAN RSPAN

基于源端口和基于源VLAN的兩種監(jiān)控方式

RX TX BOTH 三種流量方向

VLAN MONITOR只能監(jiān)控入站流,即RX,在該源VLAN中的物理端口都將成為源端口向目標(biāo)端口COPY流.可以分配多個(gè)源端口或VLAN的RX流量到目的端口.不能監(jiān)控多個(gè)端口的出站流,可以監(jiān)控單個(gè)端口的出站流.最多只能配置兩個(gè)監(jiān)控會(huì)話.源端口和目標(biāo)端口是分離的.可以將TRUNK端口配置成源端口,然后使用VLAN過濾想要被分析的流,但是此命令不影響正常的流量轉(zhuǎn)發(fā).過濾功能不能使用在基于源VLAN的情況下.#p#

目標(biāo)端口

不能是源端口或反射端口

不參加二層協(xié)議:CDP VTP PAGP LACP DTP STP

在本地SPAN中,目標(biāo)端口和源端口是同一交換機(jī).一次只能參加一個(gè)SPAN會(huì)話,即不能在一個(gè)端口上配置兩個(gè)SPAN會(huì)話.不能是EC成員.如果目標(biāo)端口是一個(gè)源VLAN成員,則這個(gè)VLAN的流量不能被MONITOR,其他VLAN可以被MONITOR.802.1X與SWITCHPORT PORT-SECURITY必須在目標(biāo)端口關(guān)閉.SPAN可以MONITOR二層協(xié)議信息,RSPAN則不能.IDS或IPS設(shè)備對流量唯一的影響是:根據(jù)IPS IDS策略,對可能的攻擊行為做出處理,如RESET TCP連接等;并不去干涉正常流量的轉(zhuǎn)發(fā).SPAN交換機(jī)端口分析,簡單的SPAN只需要兩個(gè)命令即可

  1. monitor sess 1 sour int f1/4  
  2. monitor sess 1 dest int f1/9 

此例將F1/4的流量發(fā)送到F1/9被分析

  1. Switch(config)# no monitor session 2 刪除語法  
  2. Switch(config)# monitor session 2 source vlan 1 - 3 rx  
  3. Switch(config)# monitor session 2 destination interface gigabitethernet0/7  
  4. Switch(config)# monitor session 2 source vlan 10 rx  
  5. Switch(config)# end 

在所有的端口上監(jiān)控VLAN1-3的收到的流量,發(fā)送到G0/7被分析,然后附加VLAN10的流量也被分析

  1. Switch(config)# monitor session 2 source interface gigabitethernet0/4 rx  
  2. Switch(config)# monitor session 2 filter vlan 1 - 5 , 9  
  3. Switch(config)# monitor session 2 destination interface gigabitethernet0/8  
  4. Switch(config)# end 

監(jiān)控G0/4上收到的只包括VLAN1-5 VLAN9的流量,發(fā)送到G0/8端口被分析.注意與上例的區(qū)別:也就是說在定義源流量的時(shí)候是有兩種方式的,一種是源端口的流量,一種是VLAN流量#p#

RSPAN配置:

第一步:在所有交換機(jī)上將一個(gè)指定的VLAN提供給遠(yuǎn)程SPAN使用

  1. Switch(config)# vlan 901  
  2. Switch(config-vlan)# remote span  
  3. Switch(config-vlan)# end 

第二步,配置源交換機(jī)

  1. Switch(config)# monitor session 1 source interface fastethernet0/10 tx  
  2. Switch(config)# monitor session 1 source interface fastethernet0/2 rx  
  3. Switch(config)# monitor session 1 source interface fastethernet0/3 rx  
  4. Switch(config)# monitor session 1 source interface port-channel 102 rx  
  5. Switch(config)# monitor session 1 destination remote vlan 901 reflector-port  
  6. fastethernet0/1  
  7. Switch(config)# end 

第三步,目標(biāo)交換機(jī)配置

  1. Switch(config)# monitor session 1 source remote vlan 901  
  2. Switch(config)# monitor session 1 destination interface fastethernet0/5  
  3. Switch(config)# end  
  4. This example shows how to disable received traffic monitoring on port 1, which was configured for  
  5. bidirectional monitoring:  
  6. Switch(config)# no monitor session 1 source interface fastEthernet0/1 rx  
  7. The monitoring of traffic received on port 1 is disabled, but traffic sent from this port continues to be  
  8. monitored. 

遠(yuǎn)程VLAN的監(jiān)控

  1. Switch(config)# no monitor session 2  
  2. Switch(config)# monitor session 2 source vlan 1 - 3 rx  
  3. Switch(config)# monitor session 2 destination remote vlan 902 reflector-port  
  4. gigabitethernet0/7  
  5. Switch(config)# monitor session 2 source vlan 10 rx  
  6. Switch(config)# end  
  7. Switch(config)# no monitor session 2  
  8. Switch(config)# monitor session 2 source interface gigabitethernet0/4 rx  
  9. Switch(config)# monitor session 2 filter vlan 1 - 5 , 9  
  10. Switch(config)# monitor session 2 destination remote vlan 902 reflector-port  
  11. gigabitethernet0/8  
  12. Switch(config)# end 

 

責(zé)任編輯:佟健 來源: hi.baidu.com
相關(guān)推薦

2010-09-17 12:38:07

2009-09-14 13:25:08

LINQ多方面探討

2009-07-03 10:04:04

JSP ASPJSP ASP區(qū)別

2015-10-26 14:49:21

物聯(lián)網(wǎng)物聯(lián)網(wǎng)集成

2012-07-24 11:42:32

Python

2011-04-18 17:30:04

開源iPhoneAndroid

2009-05-08 15:16:09

PHP 5.3.0測試發(fā)布

2011-01-14 16:01:27

2020-03-01 22:07:38

信息泄露數(shù)據(jù)安全

2011-05-04 17:32:15

2010-10-29 13:33:39

惠普解決方案

2017-11-22 05:58:57

支付寶微信支付互聯(lián)網(wǎng)

2024-06-18 07:46:13

2021-02-02 14:46:38

數(shù)據(jù)中心新基建綠色數(shù)據(jù)中心

2010-09-27 10:19:09

DHCP工作流程

2010-07-30 13:06:22

NFS端口

2010-07-01 15:06:23

SNMP服務(wù)配置

2010-05-10 14:39:43

網(wǎng)絡(luò)負(fù)載均衡

2010-09-01 09:00:56

DHCP OPTION

2013-07-18 17:09:20

IPv6啟動(dòng)IPv6采用率
點(diǎn)贊
收藏

51CTO技術(shù)棧公眾號