|
Switch Port Mirroring
The advent of switched networks resulted in Network IDS having great difficulty in promiscuously monitoring their networks. This was overcome by configuring a switch to replicate the data from all ports or VLAN's onto a single port. This function has a multitude of names including; Port Mirroring, Monitoring Port, Spanning Port, SPAN port and Link Mode port. Generally Port Mirroring usually indicates the ability to copy the traffic from a single port to a mirror port but disallows any type of bidirectional traffic on the port. Spanning Port usually indicates the ability to copy traffic from all the ports to a single port but also typically disallows bidirectional traffic on the port. In the case of Cisco, SPAN stands for Switch Port ANalyzer. Some switches do not allow SPAN ports to transmit packets, this is an issue if you wish to use IDS TCP countermeasures such as resets. It may also be worth looking at Network Taps which allow you to tap into a network, taking a parallel feed for the Network IDS Links to Products
Extreme Switches Newer
Submitted By Kevin Farnes Information Updated: 16 Aug 2004 {enable | disable} mirroring on port Port No configure mirroring { add | delete } { vlan VLAN | port Port No } The first line basically turns on or off the mirroring and what port the mirrored output should be sent to. The second line specifies what is to be mirrored. The second line can be repeated any number of times. There are some limitations on capability however, such as if you are mirroring a port then it must be on the same blade as the port being mirrored to. Extreme Switches Older eg 48 ExtremeWare Version 4.1 Submitted By Joel Snyder Information Updated: 16 Aug 2004 In the older Summit Extremes (like the 48, not the 48i), you are blocked at v4 of their software enable mirror to port <port-no> (both enables mirroring, and says where to send it. Notice that you cannot provide a list of ports, unfortunately) disable mirror (disables mirroring) config mirror add port <portno> (adds port <portno>, all VLANs that this port participates in) config mirror add port <portno> vlan <vlan name or #> (adds port <portno>, but only VLAN <vlan> traffic will be mirrored) config mirror add vlan <vlan name or #> (adds all ports that have this VLAN) You can add more than one port by repeating the above lines. config mirror del port <portno> config mirror del vlan <vlan> (does the obvious thing) show mirror (shows status of mirroring, including whether the port is up or not (!)) One thing to be careful of in the Extreme is that with mirroring (at least in this version of the O/S), you get both IN and OUT mirroring, which means that if you pick a VLAN as the mirror object, you may see the same frame a couple of times if it goes in one port on the VLAN and out a different one. Cisco Catalyst SPAN Support Submitted By Mark McDonagh Information Updated: 16 Aug 2004 Switch SPAN Sessions TCP Countermeasures 2900/3500XL No Limit No 2950 1 Yes 3550 2 Yes 3750 2 Yes 4000 w CatOS 5 Yes 4500 w Native IOS 6 (both considered 2) No 6000 w CatOS 2 Rx or Both, 4 Tx Yes 6000 w Native IOS 2 No Cisco Catalyst 2900/3500XL Submitted By Mark McDonagh Information Updated: 17 Aug 2004 c3550(config)#monitor session 1 source ? interface SPAN source interface remote SPAN source Remote vlan SPAN source VLAN c3550(config)#monitor session 1 source interface fa0/1 - 3 rx c3550(config)#monitor session 1 destination interface fa0/24 Only an Rx SPAN session can have multiple source ports. Note the spaces in syntax when specifying multiple interfaces. Can be “–” or “,” With Source VLAN's c3550(config)#monitor session 1 source vlan 1 - 10 rx c3550(config)#monitor session 1 destination interface fa0/24 TCP Resets c3550(config)#monitor session 1 source vlan 1 - 10 rx c3550(config)#monitor session 1 destination interface fa0/24 ingress vlan 1 The Catalyst 2950/3550 will allow you to configure a single VLAN to receive untagged TCP Reset packets. TCP Reset support is configured through the “ingress vlan” keywords. Only one VLAN is permitted. In this example, non-802.1q-tagged TCP Resets to servers or attackers existing on or through VLAN 1 would be allowed, but not if the attack or target was on VLAN 2-10. If the RST is a response to an attack detected by IDS 4.x where the 802.1q tag has been maintained, the RST will be sent on the appropriate VLAN. If you are monitoring a VLAN trunk port, you may wish to filter one or more of the VLANs on that trunk. This example only monitors VLANs 5 and 100-200 on the trunk. c3550(config)#monitor session 1 source interface gigabit0/1 c3550(config)#monitor session 1 filter vlan 5 , 100 - 200 c3550(config)#monitor session 1 destination interface fa0/24 If the monitor session destination port is a trunk, you should also use keyword ‘encapsulation dot1q’. If you do not, packets will be sent on the interface in native format. Cisco Catalyst 2950 3550 3750 Submitted By Mark McDonagh Information Updated: 17 Aug 2004 int fa0/24 Cisco Catalyst 4000 6000 with CatOS Switches Submitted By Mark McDonagh Information Updated: 16 Aug 2004 On Cat6k: On Cat4k: Syntax for Cat4k: Syntax for Cat6k: set span 2-3 5/7 create |

