BGP Autonomous System (AS) Numbers

In a recent class I was asked for some details on BGP Autonomous System (AS or ASN) Numbers.  I thought I would document and provide a more complete answer here for others to learn from as well.

What is the AS Number?

Let’s begin with a definition.  An Autonomous System Number (AS number or simply ASN) is a special number assigned by IANA (the Internet Assigned Numbers Authority) used primarilly with Border Gateway Protocol (BGP) and EIGRP that uniquely identifies a network under a single technical administration that has a unique routing policy, or is multi-homed to the public Internet. This ASN is required if you are to run the BGP routing protocol and peer with your next tier Internet provider, and it is required when running BGP between service providers at peering points and Internet Exchanges (IX).  Each autonmous system must have a globally unique ASN so that the network IP address blocks appear to come from a unique network on the Internet. BGP uses AS numbers to buils a path of networks (AS Paths) to determine the shortest path to a destination network prefix indicating where in the Internet a prefix is located.
There are 16-bit AS numbers and newer 32-bit AS numbers which were created when the original 16 bit ASN pool from IANA approached exhaustion, and the ASN field was extended the field from 16 to 32 bits [additional references: RFC4893 and RFC5398]. 
 
ASN’s can represent both IPv4 and IPv6 prefixes in networks.
 
Here is a short table that provides a breakdown of both the 16 bit and 32 bit address assignments.  The newer 32 bit version of the ASN includes all the 16 bit numbers for backwards compatibility.
 
Number # of Bits Description References
0 16 Reserved [RFC1930]
1 – 23455 16 Public ASN’s  
23456 16 Reserved for AS Pool Transition [RFC6793]
23457 – 64534 16 Public ASN’s  
64000 – 64495 16 Reserved by IANA  
64496 – 64511 16 Reserved for use in documentation/sample code [RFC5398]
64512 – 65534 16 Reserved for Private Use  
65535 16 Reserved  
65536 – 65551 32 Reserved for use in documentation and sample code [RFC4893 and RFC5398]
65552 – 131071 32 Reserved  
131072 – 4199999999 32 Public 32-bit ASN’s  
4200000000 – 4294967294 32 Reserved for Private Use [RFC6996]
4294967295 32 Reserved

 

To see a complte list of ASN assignments visit the IANA page here: https://www.iana.org/assignments/as-numbers/as-numbers.xhtml
 

Where do I get an ASN?

As stated earlier, IANA controls the AS Number assignments.  However, they assign blocks of AS numbers to the Regional Internet Registries or RiR’s.

Individual companies and providers in turn get their AS numbers from their local RIR.  The RIR that applies to you or your company is based on your physical location.  You must formally apply to the RIR to obtain an ASN. ASN’s are usually provided for a ‘container fee’ which is a fancy way of saying that they will charge you money to open an account and place the AS number under your account. You do not own the AS number, instead, think of it as a lease.

Each RIR has their own web page and you must download or complete forms to apply for your ASN.  Below is a list of the RIRs and associated links:

General ASN Assigment Requirements

There are a limited number of ASN available, so the RIR’s are very selective about whom they grant an ASN to. You will need to demonstrate the following:

  1. That you have a connection to more than one ISP (or will in the next 30 days). This is called being ‘multi-homed’.
    1. You will be asked to specify the exterior routing protocol used to communicate with your ISP (this is exclusively BGP today)
    2. You will be asked to provide the AS numbers (ASN) of all your ISP’s.
    3. You may be asked to provide the IP addresses of your ISP’s routers to which you connect. You will already know this information as it will be provided when the ISP provides your circuit, but you can discover it with a traceroute if the connection is already working.
    4. You and your ISP must already have an identity on file in the RIR’s database
  2. You must have blocks of IP addresses that need routing. You obtain IP addresses from RIR’s as well.
  3. You must demonstrate a need to utilize BGP with an organizationally unique route policy OR be multi-homed.

The Difference Between Public and Private ASN’s

As shown in the chart above, there are both public ASN’s and private ASN’s. Several RFC’s outline which addresses are private and which are public, including some special-use ASN’s for documentation and/or sample code and for AS number pool transitions. The most used are the public and private ASN’s.

PUBLIC ASN

An ASN in the public range is globally unique and may be announced on the global Internet to your ISP or at an internet exchange point (peering point) via BGP. ASN’s are used to uniquely identify networks or systems of networks which appear to the outside world to be running a single consistent routing policy. Prefixes are ‘seen’ to originate from these public ASN by the exterior gateway routing protocol (BGP). This ensures that routes lead back to a unique source of a given range of IP addresses.

PRIVATE ASN

The private ASN should not be seen on the global Internet (they shouldn’t be announced via your exterior gateway routing protocol). Private AS numbers are used by ISP’s who use BGP confederations or in private networks. Private AS numbers are also sometimes used to provide an AS number to customers with multiple connections to their ISP, but who have no connections to any other Internet service provider. This is becoming more and more rare. Use of private ASN is more frequent in private networks that will never communicate directly with the Internet. Most ISPs utilize route filters to reject routes that contain private ASN’s.

A Bibliography of Associated RFC’s

I have compiled a bibliography of associated BGP/ASN RFC’s below.  Am I missing any?  Please comment below.

  • “A Border Gateway Protocol 4 (BGP-4).” 1995. Request for Comments RFC 1771. Internet Engineering Task Force. https://doi.org/10.17487/RFC1771.
  • Bates, Tony J., Ravi Chandra, Yakov Rekhter, and Dave Katz. 2007. “Multiprotocol Extensions for BGP-4.” Request for Comments RFC 4760. Internet Engineering Task Force. https://doi.org/10.17487/RFC4760.
  • Borkenhagen, Jay, Randy Bush, Ron Bonica, and Serpil Bayraktar. 2019. “Policy Behavior for Well-Known BGP Communities.” Request for Comments RFC 8642. Internet Engineering Task Force. https://doi.org/10.17487/RFC8642.
  • Chen, Enke, John Scudder, Prodosh Mohapatra, and Keyur Patel. 2015. “Revised Error Handling for BGP UPDATE Messages.” Request for Comments RFC 7606. Internet Engineering Task Force. https://doi.org/10.17487/RFC7606.
  • Chen, Enke, and Quaizar Vohra. 2007. “BGP Support for Four-Octet AS Number Space.” Request for Comments RFC 4893. Internet Engineering Task Force. https://doi.org/10.17487/RFC4893.
  • Haas, Jeffrey, and Jon Mitchell. 2014. “Reservation of Last Autonomous System (AS) Numbers.” Request for Comments RFC 7300. Internet Engineering Task Force. https://doi.org/10.17487/RFC7300.
  • Hawkinson, John A., and Tony J. Bates. 1996. “Guidelines for Creation, Selection, and Registration of an Autonomous System (AS).” Request for Comments RFC 1930. Internet Engineering Task Force. https://doi.org/10.17487/RFC1930.
  • Huston, Geoff. 2008. “Autonomous System (AS) Number Reservation for Documentation Use.” Request for Comments RFC 5398. Internet Engineering Task Force. https://doi.org/10.17487/RFC5398.
  • Li, Tony, Ravi Chandra, and Paul S. Traina. 1996. “BGP Communities Attribute.” Request for Comments RFC 1997. Internet Engineering Task Force. https://doi.org/10.17487/RFC1997.
  • Meyer, David, and Keyur Patel. 2006. “BGP-4 Protocol Analysis.” Request for Comments RFC 4274. Internet Engineering Task Force. https://doi.org/10.17487/RFC4274.
  • Mitchell, Jon. 2013. “Autonomous System (AS) Reservation for Private Use.” Request for Comments RFC 6996. Internet Engineering Task Force. https://doi.org/10.17487/RFC6996.
  • Rekhter, Yakov, Tony J. Bates, Ravi Chandra, and Dave Katz. 1998. “Multiprotocol Extensions for BGP-4.” Request for Comments RFC 2283. Internet Engineering Task Force. https://doi.org/10.17487/RFC2283.
  • ———. 2000. “Multiprotocol Extensions for BGP-4.” Request for Comments RFC 2858. Internet Engineering Task Force. https://doi.org/10.17487/RFC2858.
  • Rekhter, Yakov, Susan Hares, and Tony Li. 2006. “A Border Gateway Protocol 4 (BGP-4).” Request for Comments RFC 4271. Internet Engineering Task Force. https://doi.org/10.17487/RFC4271.
  • Tappan, Dan, Yakov Rekhter, and Srihari R. Sangli. 2009. “4-Octet AS Specific BGP Extended Community.” Request for Comments RFC 5668. Internet Engineering Task Force. https://doi.org/10.17487/RFC5668.
  • Traina, Paul S. 1995. “BGP-4 Protocol Analysis.” Request for Comments RFC 1774. Internet Engineering Task Force. https://doi.org/10.17487/RFC1774.
  • Traina, Paul S., John Scudder, and Danny R. McPherson. 2007. “Autonomous System Confederations for BGP.” Request for Comments RFC 5065. Internet Engineering Task Force. https://doi.org/10.17487/RFC5065.
  • Vohra, Quaizar, and Enke Chen. 2012. “BGP Support for Four-Octet Autonomous System (AS) Number Space.” Request for Comments RFC 6793. Internet Engineering Task Force. https://doi.org/10.17487/RFC6793.

 

Leave a Comment

Contact Us Here


Please verify.
Validation complete :)
Validation failed :(
 
Your contact request has been received. We usually respond within an hour, but please be patient. We will get back to you very soon.
Scroll to Top