BGP 4-Byte AS Number

Hello Narad

A 4 byte AS number is represented by 32 bits. For AS numbers less than 65536, these numbers are simply represented as numbers ranging from 1 to 655356. For larger numbers, ASdot represents them as two 16 bit numbers separated by a dot. So for example:

  • An AS number of 00000000 00000000 00000000 11111111 is
  1. 256 in decimal
  2. 256 in Asdot
  3. 0.256 in Asdot+
  • An AS number of 00000000 00000000 11111111 11111111 is
  1. 65535 in decimal
  2. 65535 in Asdot
  3. 0.65535 in Asdot+
  • An AS number of 00000000 00000001 11111111 11111111 is
  1. 131071 in decimal
  2. 1.65535 in Asdot
  3. 1.65535 in Asdot+

So if the two leftmost octets are zeros, then Asdot is the same as decimal. If however there is even a single “1” in any of the two leftmost octets, Asdot will revert to Asdot+.

I hope this has been helpful!

Laz