Friday, December 14, 2012

Ubiquiti Unifi POE

The Ubiquiti Unifi is a fairly cheap and straightforward managed WiFi solution if you are happy with a L2 bridging architecture with not too much additional stuff.
My biggest issue with the hardware is the non-standard POE implementation, which uses 24V "Ubiquiti POE".

Based on the datasheet and experience (http://www.ubnt.com/downloads/datasheets/unifi/UniFi_AP_Datasheet.pdf), our base UAP devices can't directly use 802.3af POE, only the Pro UAP-Pro models can do that. Luckily, an official POE-adapter is sold by Ubiquiti (http://www.ubnt.com/8023af), and it's pretty cheap.

The 802.3af POE is 48V, but fear not: standard POE uses a detection mechanism before sending out the juice, so it won't fry your Unifi AP if you connect it directly to a POE switch, it just won't start up.

If you want to go with long cable runs, as higher voltage is better suited for longer runs, I'd suggest to use standard 48V POE to drive the cable, and use the Unifi adapter near the AP to convert it to 24V.

Thursday, December 6, 2012

Fun factsheet for Cisco 3500XL and 2900XL switches

It still seems like a popular topic, and these switches never really die, so here are some fun facts about them that I found to be useful (both from my experience and from the documentation):
  • These are layer 2 switches;
  • So they don't have DHCP snooping capabilities;
  • Nor any ARP inspection (DAI).
  • They can't do IP routing, or NAT.
  • Traffic distribution over an etherchannel can be based on source or destination MAC addresses, but not both. Distribution can be configured per etherchannel, not just system-wide. You can't distribute based on layer3-4 (IP,TCP/UDP) info.
  • No layer3 ACLs for switching. (Just for the control plane).
  • They have 2 hardware priority queues.
  • They only support L2 COS, not DSCP or TOS.
  • For IP phones, you have to go with a switchport trunk, encapsulation dot1q, nonegotiate, native vlan , allowed vlan ,, swichport voice vlan  type of setup.
  • The 3500XL and 2900XL use the same software, you can run 2900XL images on a 3500XL box.
  • The only members of the 2900XL family with Gigabit ports are the modular, 2U high chassis.
  • They do not support MSTP and GVRP.
  • They do not support LLDP.
  • The 2900 series does not support POE; but some 3500 series models do: look for the -PWR in the model name.
So far that's it, I might extend the list if something comes to mind.

Friday, November 30, 2012

Ethernet filtering fun in hexa with D-Link DES-3250

Most network admins in education know that the source of the most evil is the dormitory. Mostly ignorance with just a touch of malice for the flavor. Rogue DHCP servers, IPv6 router advertisements, IP collisions and the occasional ARP spoofing.

The D-Link DES-3250 series is our choice of switch for our dormitory, as it's cheap and fairly reliable. It can't perform proper DHCP snooping, dymanic-ARP-inspection or even the ARP protection the DES-3526 can, but it can do some filtering, based on IP, MAC or raw ethernet packets.

Credits for the first two go to Gavin McCullagh, not me.

You can filter DHCP replies easily:


create access_profile ip udp src_port_mask 0xFFFF port 1-48 profile_id 1 
config access_profile profile_id 1 add access_id 1 ip udp src_port 67 deny 


Now this one is a thing of beauty: filtering IPv6 Router advertisements:


create access_profile packet_content_mask offset_0-15  0x0  0x0  0x0  0xFFFF0000 offset_16-31  0x0  0xFF000000  0x0  0x0 offset_48-63  0x0  0xFF00  0x0  0x0 port 1-48 profile_id 2 
config access_profile profile_id 2 add access_id 1 packet_content offset_0-15  0x0  0x0  0x0  0x86DD0000 offset_16-31  0x0  0x3A000000  0x0  0x0 offset_48-63  0x0  0x8600  0x0  0x0 deny 


IPv6 uses ethertype 0x86dd, and the type for RA in ICMPv6 is 0x86

Yesterday I had 4 TP-Link APs configured as 192.168.1.254. This wouldn't be a big issue normally, but these ones were dead-set on sending gratuitous ARPs against each other at speeds of 10Mpps...
The DES-3250 has broadcast control, which was set at 8pps, but something went wrong, as the switches still forwarded around 4kpps of ARPs on all ports.
So next up is IPv4 ARP filtering for anything with the source 192.168.0.0/16:


create access_profile packet_content_mask offset_0-15  0x0  0x0  0x0  0xFFFF0000 offset_16-31  0x0  0x0  0x0  0xFFFF0000 port 1-48 profile_id 3 
config access_profile profile_id 3 add access_id 1 packet_content offset_0-15  0x0  0x0  0x0  0x08060000 offset_16-31  0x0  0x0  0x0  0xC0A80000 deny 

The ethertype for ARP is 0x8060, and 192.168 is 0xc0a8.

ARP spoofing of the gateway is not that popular on this subnet, but next time it happens, I'll do an entry with that.

Edit: 19/02/2013 - fixed ethertype value in ARP filter

Sunday, November 25, 2012

3Com 4050 and D-Link DGS-3324SR spanning tree native vlan

My new place uses a 3Com 4050 as a layer2 core/distribution switch. It's linked to DES-3526, DGS-3324SR and DGS-3100 switches. Protocol of choice is RSTP. Without native/untagged vlan on the links, the following happens:

  • 3Com 4050 - DES-3526 - RSTP works okay
  • 3Com 4050 - DGS-3100 - RSTP breaks, needs vlan1 untagged
  • 3Com 4050 - DGS-3224SR - RSTP breaks, needs vlan1 untagged
  • 3Com 4050 - DES-3052P - RSTP breaks, needs vlan1 untagged
  • DGS-3224SR - DES3250 - RSTP works okay
  • DES-3526 - DES-3052P - RSTP breaks, needs vlan1 untagged
  • DGS-3324SR - 3Com 4400 - RSTP works okay
Bottom line: you've gotta love standard implementations of STP...

Alive N Kickin'

In case anybody wonders, I'm still active.
In the past 6 months I changed employment and countries, so it was a bit hectic.

My new place primarily uses Fortigate, Vyatta, D-Link and old 3Com gear, so expect less Cisco for a while. HP will be on the plate as I'm going for the ASE and MASE.
On a related note, I'm Brocade BCNE and BCNP since July, thanks to the BNCE/P 2012 beta program.

So for the time being, stay tuned for D-Link and 3Com stuff.