How to see which WiFi Mac Addresses correspond to Aerohive APs?

  • 1
  • Question
  • Updated 3 years ago
I'm runnning scan on my mac and I see some Mac Addresses that are broadcasting on the same channel. It's another AP in my office, but how do I find out which one? I'm not connected to it, and I don't know how to reverse lookup the 5Ghz WiFi mac address of that AP to it's AP name in Hivemanager

Thanks
Photo of David

David

  • 18 Posts
  • 0 Reply Likes

Posted 3 years ago

  • 1
Photo of Crowdie

Crowdie, Champ

  • 972 Posts
  • 272 Reply Likes
To bring up the BSSIDs SSH into the access point(s) and run a show int command.  The BSSID will appear in the "Name" column, channel in the "Chan (Width)" column and SSID in the "SSID" column.

We have filed a feature request for a "BSSID" column in the "Aerohive APs" screen but haven't seen it implemented yet.
(Edited)
Photo of Brian Powers

Brian Powers, Champ

  • 396 Posts
  • 92 Reply Likes
To add to what Crowdie said, you can do some basic "hex math" to figure out which BSSID goes to which MAC/AP... 

If MAC address is 9C:5D::12:C9:8D:00,
the BSSIDs will be as follows:

2.4 GHz radios on the AP will be 9C:5D::12:C9:8D:1? (where ? starts at 4 and increments 1 per SSID on said radio)
5 GHz radios will be 9C:5D::12:C9:8D:2? (where ? starts at 4 and increments 1 per SSID on said radio).

So if you have 3 SSIDs on each AP (both set to dual band), the BSSIDs will be:

2..4 GHz BSSIDs
9C:5D::12:C9:8D:14
9C:5D::12:C9:8D:15
9C:5D::12:C9:8D:16

5 GHz BSSIDs
9C:5D::12:C9:8D:24
9C:5D::12:C9:8D:25
9C:5D::12:C9:8D:26

The 2nd to last character is always 1 for 2.4 GHz BSSIDs and 2 for 5 GHZ BSSIDs.  Depending on how many SSIDs have been created in the past however, the last character could be higher (up into even a,b,c - think hex 0-f).
Photo of Nick Lowe

Nick Lowe, Official Rep

  • 2491 Posts
  • 451 Reply Likes
You just mask off the last octet to determine which BSSIDs correspond to the same AP, the 6th octet.
(Edited)
Photo of Brian Powers

Brian Powers, Champ

  • 396 Posts
  • 92 Reply Likes
In most all cases, yes, this will work.  But if you have 2 APs with MAC that are 9C:5D:12:C9:8D:80 and 9C:5D:12:C9:8D:40, the last two digits are the only difference and are needed to know which goes where.  In this cast the BSSIDs will end with :94 and :A4 for one AP an :54 & :64 for the other.  
Photo of Nick Lowe

Nick Lowe, Official Rep

  • 2491 Posts
  • 451 Reply Likes
Brian is right. I have just checked and the masking does needs to be more specific than to the whole of the last octet/byte.

On the last octet/byte, you will need to 'zero out' the bits covered by 0x3F to get what you want when performing a comparison. Those 6 bits are used to distinguish between things on the same AP.

(The inverse for that octet/byte is 0xC0.)

The bitwise AND operation, signified below by the & operator, is our friend here.

Where the following pseudo code/condition equates to TRUE then, it is the same AP:

boolean sameAp = (AP_MAC & ~0x3F) == (BSSID & ~0x3F);

or

boolean sameAp = (AP_MAC & 0xFFFFFFFFFFC0) == (BSSID & 0xFFFFFFFFFFC0);

The following may also be useful for BSSIDs:

boolean is2_4GHz = (BSSID & 0x30) == 0x10;

boolean is5GHz = (BSSID & 0x30) == 0x20;

(Edited)
Photo of Nick Lowe

Nick Lowe, Official Rep

  • 2491 Posts
  • 451 Reply Likes
You first can determine which BSSIDs correspond to Aerohive APs by looking at the first three octets, the OUI bits.

Aerohive currently have 10 OUIs assigned to them. These are, in order of issuance:

C4-13-E2
B8-7C-F2
F0-9C-E9
40-18-B1
00-19-77
88-5B-DD
08-EA-44
D8-54-A2
E0-1C-41
9C-5D-12
(Edited)
Photo of Nick Lowe

Nick Lowe, Official Rep

  • 2491 Posts
  • 451 Reply Likes
I have written quick and simple code to demo what I wrote about in the comment above. It can be executed in a Web browser via the awesome C# Pad:

http://csharppad.com/gist/79f435ad5ef500a50712

Click on Go, wait for it to return, scroll to the bottom and then type in the BSSID...

Tool.Check("9C:5D:12:C9:8D:62");

Tool.Compare("9C:5D:12:C9:8D:62", "9C:5D:12:C9:8D:64");

...and click on Go again.

Rinse, repeat with more Tool.Check(...) or Tool.Compare(...) commands.

You should get an output like:
(Edited)