Arama Yap Mesaj Gönder
Biz Sizi Arayalım
+90
X
X
X
X

Knowledge Base

Homepage Knowledge Base General What is an ASN? What is an ASN Numb...

Bize Ulaşın

Konum Halkalı merkez mahallesi fatih cd ozgur apt no 46 , Küçükçekmece , İstanbul , 34303 , TR

What is an ASN? What is an ASN Number Used For? A Comprehensive Guide

What is an ASN?

ASN (Autonomous System Number) can be translated into Turkish as Özerk Sistem Numarası (Autonomous System Number). It is one of the fundamental building blocks of the Internet and is used to identify large networks (autonomous systems) on the Internet. An ASN is a group of IP networks under a single technical administration that follows a common routing policy.

Autonomous systems are usually operated by large organizations, internet service providers (ISPs), educational institutions, or large companies. Each ASN is identified by a unique number, which determines how the network interacts with other networks on the Internet.

Key Points:

  • ASN identifies the identity of networks on the Internet.
  • Represents a group of IP networks under a single technical administration.
  • Follows a common routing policy.
  • Generally used by large organizations and ISPs.

What Does an ASN Number Do?

The primary function of an ASN number is to facilitate routing operations on the Internet. It is especially used with the routing protocol known as BGP (Border Gateway Protocol). BGP uses ASN numbers to determine the best path between different autonomous systems.

Functions of ASN Number:

  1. Routing: ASN numbers ensure that data packets reach the correct destination on the Internet. BGP uses ASN numbers to determine the most appropriate path and routes data packets over this path.
  2. Policy Enforcement: ASN holders can implement routing policies to control traffic passing through their networks. These policies can filter or prioritize traffic coming from or going to specific ASNs.
  3. Security: ASN numbers can be used to enhance network security. For example, it is possible to block or monitor suspicious traffic coming from specific ASNs.
  4. Resource Management: ASN numbers help manage IP addresses and other Internet resources efficiently.

Real-Life Example:

An internet service provider (ISP) may have its own network, which provides internet access to many different customers. The ISP obtains an ASN number to represent its network. This ASN number determines how the ISP's network interacts with other networks on the Internet. For example, the ISP can prioritize traffic passing through its ASN or block traffic coming from specific ASNs.

How to Obtain an ASN Number?

To obtain an ASN number, it is necessary to apply to a RIR (Regional Internet Registry). There are five RIRs worldwide:

  • ARIN: North America
  • RIPE NCC: Europe, the Middle East, and Central Asia
  • APNIC: Asia-Pacific region
  • LACNIC: Latin America and the Caribbean
  • AfriNIC: Africa

Turkey is located in the RIPE NCC region. Therefore, an organization in Turkey needs to apply to RIPE NCC to obtain an ASN number.

ASN Number Acquisition Process:

  1. Check the Application Requirements: The requirements for RIRs to issue ASN numbers may vary. Before applying, visit the relevant RIR's website to check the requirements. Generally, a network must have multiple upstream connections and use BGP.
  2. Fill Out the Application Form: Download the application form from the RIR's website and fill it out completely. In the form, you will need to provide information such as the technical details of your network, your routing policies, and your contact information.
  3. Prepare the Necessary Documents: The RIR may request additional documents to evaluate your application. These documents may be documents proving your company's legal status, your network's topology, and your routing policies.
  4. Submit the Application: Submit the application form and the necessary documents to the RIR. Your application will be reviewed and evaluated by the RIR's experts.
  5. Pay the Fee: You may need to pay a fee to obtain an ASN number. The fee may vary depending on the RIR and the type of ASN number.
  6. Get the ASN Number: If your application is approved, the RIR will assign you an ASN number. You can use this number in your network's routing settings.

Example:

A Turkish company wants to set up its own data center and connect directly to the internet. The company plans to obtain connections from multiple internet service providers (ISPs) and manage these connections using BGP. In this case, the company can apply to RIPE NCC for an ASN number. During the application process, the company will need to provide RIPE NCC with the technical details of its network, its routing policies, and its connections with ISPs.

What is the Relationship Between BGP and ASN?

BGP (Border Gateway Protocol) is a protocol used to share routing information between autonomous systems (AS) on the internet. BGP informs each AS of which IP addresses it owns and how to reach those addresses. ASN numbers are one of the fundamental building blocks of BGP and are used to uniquely identify ASs.

How BGP Works:

  1. Neighborhood Relationship: BGP establishes a neighborhood relationship between neighboring ASes. This neighborhood relationship means that two ASes can share routing information with each other.
  2. Routing Information Sharing: Neighboring ASes send each other routing information indicating which IP addresses they own and how to reach those addresses. This information includes ASN numbers and IP address blocks.
  3. Determining the Best Path: Each AS uses the routing information it receives to determine the best path to reach other networks from its own network. In this process, ASN numbers, path length (AS-PATH), and other routing policies are used for evaluation.
  4. Creating the Routing Table: Each AS stores the best paths it determines in a routing table. This table shows which IP addresses the AS can reach via which path.
  5. Routing Data Packets: When a data packet reaches an AS, the AS looks at the routing table and forwards the packet to the correct destination. This process repeats until the data packet reaches its destination.

The Role of ASN in BGP:

  • ASN numbers are used to uniquely identify ASes in BGP messages.
  • ASN numbers are used in a path attribute called AS-PATH. AS-PATH indicates which ASes a data packet has passed through.
  • BGP policies can be applied based on ASN numbers. For example, it is possible to block or prioritize traffic from a specific ASN.

Code Example (BGP Configuration):


router bgp 65001
  neighbor 192.168.1.1 remote-as 65002
  network 10.0.0.0 mask 255.255.255.0

In this example, the router bgp 65001 command configures a BGP router with the ASN number 65001. The neighbor 192.168.1.1 remote-as 65002 command establishes a BGP session with a neighbor that has the IP address 192.168.1.1 and the ASN number 65002. The network 10.0.0.0 mask 255.255.255.0 command specifies that the 10.0.0.0/24 network will be advertised via BGP.

What are the Types of ASN Numbers?

ASN numbers are divided into two main types according to their length:

  • 2-byte ASN (16-bit ASN): Has numerical values ranging from 1 to 65535. However, some numbers are reserved for special purposes.
  • 4-byte ASN (32-bit ASN): Has numerical values ranging from 65536 to 4294967295. 4-byte ASNs were introduced due to the exhaustion of 2-byte ASNs and offer the ability to identify a larger number of ASes.

Comparison of ASN Types:

Feature 2-byte ASN (16-bit) 4-byte ASN (32-bit)
Value Range 1 - 65535 65536 - 4294967295
Use Case Legacy networks, small and medium-sized organizations Large networks, internet service providers (ISPs)
Support Supported by all BGP routers May not be supported by older BGP routers
Advantages Simpler configuration Greater availability of ASN numbers
Disadvantages Limited number of ASN numbers Compatibility issues with older equipment

Important Note:

Nowadays, new ASN number requests are generally allocated as 4-byte ASNs. 2-byte ASNs are generally used by legacy networks and small-scale organizations.

How are Inter-ASN Routing Policies Applied?

Inter-ASN routing policies are applied through BGP (Border Gateway Protocol). These policies determine which routes an AS will accept, which routes it will announce, and how it will route traffic. Routing policies can be used to improve network security, optimize performance, and reduce costs.

Types of Routing Policies:

  1. Filtering: Used to block or allow traffic coming from or going to specific ASNs.
  2. Prioritization: Used to mark traffic coming from or going to specific ASNs as having a higher or lower priority than other traffic.
  3. Path Manipulation: Used to change the length or preference of a path by modifying the AS-PATH attribute.
  4. Communities: Used to share routing information and coordinate policies between ASNs.

Routing Policy Implementation Steps:

  1. Policy Definition: The first step is to define the routing policy to be implemented. This policy should specify which traffic from or to which ASNs will be affected, what actions will be performed, and what criteria will be used.
  2. Access Control List (ACL) Creation: ACLs are used to identify specific IP addresses or networks. ACLs can be used for traffic filtering in routing policies.
  3. Route Map Creation: Route maps are used to implement routing policies. A route map contains one or more match conditions and one or more actions. Match conditions determine which traffic will be affected. Actions specify what to do with the traffic.
  4. BGP Configuration: Route maps are applied in BGP neighbor relationships. This means that the route map will affect traffic coming from or going to a specific neighbor.
  5. Policy Testing and Monitoring: After the routing policy is implemented, it should be tested and monitored to ensure that it is working correctly. This may involve checking routing tables, monitoring traffic flow, and analyzing logs.

Case Study:

An internet service provider (ISP) wants to implement a routing policy to protect against DDoS attacks. The ISP identifies suspicious traffic coming from a specific ASN and wants to block this traffic. The ISP can filter traffic from this ASN by creating a route map and redirecting this traffic to an invalid address. In this way, the ISP can protect its network from DDoS attacks.

How to Query ASN Information?

Various online tools and command-line tools are available to query ASN information. These tools provide the owner, contact information, IP address range, and other relevant information of an ASN number.

Online Tools:

  • WHOIS Databases: RIRs such as RIPE NCC, ARIN, APNIC, LACNIC, and AfriNIC have WHOIS databases on their websites. These databases provide information about ASN numbers, IP addresses, and domain names.
  • ASN Query Sites: Various websites such as Team Cymru, Hurricane Electric, and BGPView offer ASN query services. These sites allow you to query ASN information using an ASN number, IP address, or domain name.

Command Line Tools:

  • WHOIS Command: The WHOIS command, found in operating systems like Linux and macOS, can be used to query information about ASN numbers. For example, the command whois AS64496 provides information about the ASN number 64496.
  • bgpq3 Command: bgpq3 is a command-line tool used to create BGP filters and query ASN information. bgpq3 can query ASN information by connecting to the RIPE NCC database.

Step-by-Step Instructions (ASN Query with WHOIS Command):

  1. Open the Terminal: Open a terminal window on Linux or macOS operating systems.
  2. Run the WHOIS Command: Run the command whois AS[ASN number]. For example, run the command whois AS64496.
  3. Review the Results: The WHOIS command will display various information about the ASN number. This information may include the ASN owner, contact information, IP address range, and registration date.

Example Output (WHOIS Command):


ASNumber:       64496
ASName:         GOOGLE
ASHandle:       AS64496
RegDate:        2007-03-01
Updated:        2018-09-26
OrgId:          GOOG-2
OrgName:        Google LLC
OrgHandle:      GOOG-2
Address:        1600 Amphitheatre Parkway
City:           Mountain View
StateProv:      CA
PostalCode:     94043
Country:        US

In this example, the WHOIS command shows that the ASN number 64496 belongs to Google LLC and displays Google's contact information.

Importance of ASN Information:

ASN information is important for network administrators, security experts, and researchers. This information can be used to troubleshoot network problems, identify security threats, and understand the structure of networks on the internet.

What is the Relationship Between ASNs and IP Addresses?

ASNs (Autonomous System Numbers) and IP addresses are the fundamental building blocks of the internet and are closely related to each other. An ASN represents a group of IP networks under a single technical administration. These IP networks may have a specific IP address range (IP block).

ASN and IP Address Relationship:

  1. IP Address Ownership: An ASN owner may own a specific IP address range. These IP addresses are assigned to network devices (servers, routers, computers, etc.) under the control of the ASN.
  2. IP Address Announcement: An ASN owner announces the IP address range it owns to other ASNs via BGP (Border Gateway Protocol). This announcement allows other ASNs to know how to reach these IP addresses.
  3. Routing: Other ASNs use the announced IP address ranges to route traffic destined for these addresses to the correct ASN. This process ensures that data packets on the internet reach the correct destination.

IP Address Allocation:

IP addresses are allocated to ASN holders by RIRs (Regional Internet Registries). RIRs ensure the fair and efficient distribution of IP addresses. An ASN holder can apply to the RIR for a specific IP address range. The RIR evaluates the application and may allocate an IP address range based on the ASN holder's needs and the availability of resources.

IP Address Range Size:

The size of the IP address range is specified using CIDR (Classless Inter-Domain Routing) notation. The CIDR notation indicates how many bits of the IP address are the network address. For example, the /24 CIDR notation indicates that the first 24 bits of the IP address are the network address and the last 8 bits are the host address. Smaller CIDR values (e.g., /16) represent larger IP address ranges, while larger CIDR values (e.g., /24) represent smaller IP address ranges.

Example:

Suppose an internet service provider (ISP) has the IP address range 192.0.2.0/24. This ISP can assign these IP addresses to its customers and announce these IP addresses to other ASNs via BGP. Other ASNs will route traffic destined for 192.0.2.0/24 to this ISP.

Importance of IP Address and ASN Relationship:

The relationship between IP addresses and ASNs is important for the proper functioning of the internet. This relationship ensures that IP addresses are routed to the correct ASN and that data packets reach the correct destination. Furthermore, this relationship is also important for the management and security of networks on the internet.

Property Description
IP Address A unique numerical address used to identify devices on the internet
ASN (Autonomous System Number) A unique number that identifies a group of IP networks under a single technical administration
RIR (Regional Internet Registry) Organization that distributes IP addresses and ASNs regionally
CIDR (Classless Inter-Domain Routing) Notation used to specify an IP address range
BGP (Border Gateway Protocol) Protocol used to share routing information between ASNs

 

Can't find the information you are looking for?

Create a Support Ticket
Did you find it useful?
(3491 times viewed / 436 people found it helpful)

Call now to get more detailed information about our products and services.

Top