🗺️ BGP & Internet Routing 4 мин. чтения

ASN Numbers Explained

How Autonomous System Numbers are allocated and used in internet routing.

What Is an ASN?

An ASN (Autonomous System Number) is a unique identifier assigned to an autonomous system for use in BGP routing. Every network that participates in BGP routing must have an ASN.

ASN Formats

16-bit ASNs (Original)

  • Range: 1 – 65,535
  • Allocated until exhaustion
  • Still widely used

32-bit ASNs (Extended)

  • Range: 1 – 4,294,967,295
  • Introduced in RFC 6793 (2012)
  • Written in "asplain" notation: AS394354
  • Required for new allocations as 16-bit ASNs are depleted

How ASNs Are Allocated

The allocation follows a hierarchical model:

IANA → Regional Internet Registries (RIRs) → Organizations

The five RIRs:

RIR Region Headquarters
ARIN North America Chantilly, Virginia
RIPE NCC Europe, Middle East, Central Asia Amsterdam
APNIC Asia-Pacific Brisbane
LACNIC Latin America Montevideo
AFRINIC Africa Ebene, Mauritius

Reserved ASN Ranges

Range Purpose
0 Reserved
23456 AS_TRANS (for 32-bit ASN transition)
64496 – 64511 Documentation and examples
64512 – 65534 Private use (not announced publicly)
65535 Reserved
4200000000 – 4294967294 Private use (32-bit)

Private vs Public ASNs

  • Public ASNs are globally unique and used for peering on the public internet
  • Private ASNs (64512–65534) are used internally within organizations and stripped from BGP announcements before reaching the public internet

Looking Up ASN Information

You can look up ASN details using several methods:

# WHOIS query
whois AS13335

# Using dig for DNS-based lookup
dig +short AS13335.asn.cymru.com TXT

ASN lookups reveal the organization, country, registration date, and allocated IP prefixes.

Смотрите также