EDUCBA

EDUCBA

MENUMENU
  • Free Tutorials
  • Free Courses
  • Certification Courses
  • 600+ Courses All in One Bundle
  • Login

Address Resolution Protocol

Home » Software Development » Software Development Tutorials » Network Security Tutorial » Address Resolution Protocol

Address Resolution Protocol

Introduction to Address Resolution Protocol

Address Resolution Protocol is an address mapping technique used to dynamically map a logical address to a physical address, i.e. convert the logical address (IP address) used at the network layer to physical address (MAC address) used at the data link layer. Package of Address Resolution protocol consists of a cache table, queues, output module, input module and cache control module. Address Resolution protocol consists of  Hardware type, protocol type, Hardware length, protocol length, operations like request and reply, the hardware address of the sender, protocol address of the sender, the hardware address of target and protocol address of the target.

Address Resolution Protocol packet format

Below tables is the ARP packet format:

Start Your Free Software Development Course

Web development, programming languages, Software testing & others

Hardware & Protocol table

ARP packet format

  • Hardware type: It is a 16-bit field that defines the type of network on which address resolution protocol is running.
  • Protocol type: It is a 16-bit field that defines the type of protocol. E.g. for the IPv4 protocol, this field contains 0800 bases 16.
  • Hardware length: It is an 8-bit field that defines the physical address length in bytes.
  • Protocol length: It is an 8-bit field that defines the logical address length in bytes.
  • Operations: It is a 16-bit field that defines the types of packets. There are two types of packets ARP request (1) and ARP reply (2).
  • Sender hardware address: It is a variable-length field that defines the physical address of the sender.
  • Sender protocol address: It is a variable-length field that defines the logical address of the sender.
  • Target hardware address: It is a variable-length field that defines the physical address of the receiver.
  • Target protocol address: It is a variable-length field that defines the logical address of the receiver.

Address Resolution Protocol Operations

In this section, we will see the ARP process and four different cases where the host or router needs to use address resolution protocol.

Data Table

ARP process

Below is a list of steps involved in the ARP process:

Step 1: The sender knows the IP address of the receiver.

Step 2: Internet protocol asks ARP to create an ARP request message that contains information like sender physical address, receiver physical address field is filled with 0s, the sender IP address and receiver IP address.

Step 3: ARP request message is sent to the data link layer where the message is encapsulated in the frame using the sender’s physical address as a source address and broadcast address as a destination address.

Step 4: Each and every host receives the frame because the frame contains a broadcast destination address. All hosts check the address with their address. If the match founds the packet is dropped to that host otherwise, it passes to the address resolution protocol.

Popular Course in this category
All in One Software Development Bundle (600+ Courses, 50+ projects)600+ Online Courses | 3000+ Hours | Verifiable Certificates | Lifetime Access
4.6 (3,144 ratings)
Course Price

View Course

Related Courses
CDN Training (2 Courses)OSPF Training Program (2 Courses)Penetration Testing Training Program (2 Courses)

Step 5: After receiving the packet target host reply with an ARP reply message that contains the target physical address. The message in this step is unicast.

Step 6: When the sender receives a reply message from the target, it knows the target’s physical address.

Step 7: Now, the IP Datagram carries data for the target machine encapsulated and sent in the unicast form to the destination.

Four different cases

Below is the list of four cases where address resolution protocol services can be used.

Case 1:

Address-Resolution-Protocol- Case 1

From the above picture, we can see that the sender is a host and wants to send a packet to another host that lies on the same network. In this case, mapping the logical address to the physical address is a destination IP address should be in the datagram header.

Case 2:

Address-Resolution-Protocol- Case 2

As we can see in the above picture, the sender is a host and wants to send a packet to another host that lies on another network. In this case, the sender host looks into the routing table to find the next host’s IP address for the destination. The IP address of the host becomes the logical address that must be mapped to a physical address. If the sender host does not have a routing table, it looks at the default host’s IP address.

Case 3:

Address-Resolution-Protocol- Case 3

As we can see in the above picture, the sender is a router that received a datagram for another host that lies on another network. In this case, the router looks into the routing table and finds the next router’s IP address. The IP address of the router becomes the logical address that must be mapped to a physical address.

Case 4:

Address-Resolution-Protocol- Case 4

As we can see in the above picture, the sender is a router that received a datagram for another host that lies on the same network. In this case, the datagram’s IP address becomes the logical address that must be mapped to a physical address.

Address Resolution Protocol Package

Address Resolution Protocol Package has five components –

1.Cache table

2.Queues

3.Output module 4

4.Input module

5.Cache-control module.

Below is the Diagram of the Address Resolution Protocol Package

ARP diagram

Let’s discuss the components of the ARP package in detail.

1. Cache Table in ARP

When the host receives the IP datagram’s corresponding physical address, the Cache table saves this physical address in its table. The storing of a physical address in the cache table is limited for a specific amount of time rather than unlimited time. The cache table is consists of an array of entries. Each entry has the following mentioned field.

  • State: It shows the state of each entry. The state can be Free, Resolved or Pending. Free state means the time to live for entry has expired. That space is allocated to a new entry. Resolved state means the entry is completed. An entry has the destination physical address. Packages that are waiting to be sent to this destination can use the information in the entry. Pending state means the request for the entry has been stated and waiting for the reply.
  • Hardware type: It defines the type of network on which the ARP package is running.
  • Protocol type: It defines the type of protocol on which the ARP package is running.
  • Hardware length: It defines the length of the physical address.
  • Protocol length: It defines the length of the logical address.
  • Hardware address: It shows the destination physical address.
  • Protocol Address: It shows the destination logical address.
  • Interface number: It is an interface number that the router uses to connect with a different network.
  • Queue number: It uses queue number to enqueuer the packets that are waiting for address resolution.
  • Time-out: It shows the lifetime of each entry in the second.
  • Attempts: It shows the number of times the ARP request has been sent for each entry.

2. Queues

It contains a set of queues for the destination, i.e. one queue for each destination to hold the IP package while it resolves the physical address. The output module sends unresolved packets to their corresponding queues.

3. Output Module

  • The output model waits for IP packets. As soon as the IP packet receives, it checks the cache table to find the destination’s corresponding IP address present in the packet. The destination IP address of the packet must match the protocol address of the entry.
  • If the matching entry founds and the state of the entry are RESOLVED, then the packet with the destination hardware address is passed to the data link layer for transmission.
  • If the matching entry founds and the state of the entry are PENDING, then the packet waits until the destination’s hardware address is found.
  • If the matching entry does not find, the output module creates a queue and enqueues the packet. It creates a new entry and gives the state a PENDING and set attempts to 1. It broadcast the ARP request packet for the destination address.

4. Input Module

  • Input Module waits for the address resolution protocol packet. As soon as the address resolution packet arrives, it checks the entry corresponding to the cash table’s address resolution packet. The protocol address of the target must match the protocol address of the entry.
  • If the matching entry is found and the state of the entry is RESOLVED, the input module updates the entry and time outfield. Entry is updated because there can be chances of change in the hardware address.
  • If the matching entry is found and the state of the entry is PENDING, the input module updates the entry by copying the target’s hardware address to the hardware address field of the entry and updating the state field to RESOLVED. It also updates the timeout field of the entry.
  • If the matching entry is not found, the input module creates a new entry and adds it to the table. It updates the state field to RESOLVED and time outfield of the entry.
  • Then the input module checks whether the ARP packet that is received is a reply or request. If it is an ARP request, the input module immediately creates an ARP reply and sends it to the sender. ARP reply packet is created by changing the value of the packet from request to reply.

5. Cache-Control Module

  • The cache-control module maintains the cache table. It checks the cache table entry by entry periodically, i.e. five seconds.
  • If the state field of the entry is FREE, it checks another entry.
  • If the state field of the entry is PENDING, the cache-control module increases the attempt field’s value by 1. It then checks the value of the attempt field. If the attempt field’s value is greater than the maximum limit that is allowed, it updates the state field to FREE and destroys the corresponding queue.
  • If the state field of the entry is RESOLVED, the cache-control module decreases the time outfield value by 1. It then checks the value of the time outfield. If the time outfield value is less than or equal to zero, it updates the state field of entry to FREE and destroys the corresponding queue.

Conclusion

This article has seen what Address Resolution Protocol, packet format in ARP is, and it’s an operation with images and explanation in the sub-topics for better understanding.

Recommended Articles

This has been a guide to Address Resolution Protocol. Here we have discussed packet format, operations, as well as components of the ARP package. You can also go through our other suggested articles to learn more –

  1. What Is Networking Protocols
  2. What is ARP?
  3. TCP/IP Model
  4. Basic Fundamental Of Networking

All in One Software Development Bundle (600+ Courses, 50+ projects)

600+ Online Courses

3000+ Hours

Verifiable Certificates

Lifetime Access

Learn More

0 Shares
Share
Tweet
Share
Primary Sidebar
Network Security Tutorial
  • Protocols
    • What is TCP Protocol
    • What is TCP/IP
    • How do IP Addresses Work?
    • Routing Protocols Types
    • What is Telnet
    • What is TFTP
    • What is DHCP
    • What is SFTP
    • Address Resolution Protocol
    • Internet Control Message Protocol
    • Simple Mail Transfer Protocol
    • Internet Security Protocols
    • SMTP Protocol
    • Types of Networking Protocols
    • User Datagram Protocol
    • Data Link Layer
    • Transport Layer Protocols
    • What Is Networking Protocols
    • TFTP
    • What is ARP
    • Basic Fundamental Of Networking
    • What is IPv4
    • What is IPv6
    • CIFS Protocol
    • What is SMB?
    • What is EIGRP
    • What is LLDP?
  • Basics
    • Security Consultant Definition
    • Security Policies
    • What is Network Security
    • What is Data Security?
    • What is Cryptography
    • Cryptography Techniques
    • Cryptography Tools
    • Data Security Techniques and Privacy
    • Digital Signature Cryptography
    • Java Cryptography
    • Basics of Cybersecurity
    • What is Network Topology
    • Algorithms and Cryptography
    • HTTP Methods
    • Security Technologies
    • Security Architecture
    • Network Topologies
    • What is a Physical Address?
    • Logical Address
    • What is Storage Area Network?
    • Mobile Ad Hoc Network
    • What is Computer Networks?
  • Routing
    • What is Router
    • Types of Routers
    • Dynamic Routing
    • Routing Algorithms
    • Routing Protocol
    • What is Routing
    • What is Static Routing
    • Important Types of DNS Servers (Powerful)
  • Attacks
    • Types of Network Attacks
    • What is Trojan Horse Virus
    • What is DOS
    • Types of DOS Attacks
    • DDos Attack Mitigation
    • Ransomware Attack  
    • Types of Cyber Attack
    • What is a Brute Force Attack
    • What is a Phishing Attack
    • What is Cyber Attack
    • What is DDoS Attack
    • What is Man In The Middle Attack
    • What is Man In The Middle Attack
    • What is Ransomware
    • What is Pharming
    • What is Phishing
    • What is CSRF
    • DNS Amplification Attack
    • Denial of Service Attack
  • Algorithm
    • IDEA Algorithm
    • MD5 Algorithm
    • Symmetric Algorithms
    • Diffie Hellman Key Exchange Algorithm
    • Digital Signature Algorithm
    • Encryption Algorithm
    • Advanced Encryption Standard
    • Asymmetric Encryption
    • ElGamal Encryption
    • HMAC
    • DES Algorithm
    • Brute Force Algorithm
    • SHA Algorithm
    • RSA Algorithm
    • What is Digital Certificate?
    • Certificate Revocation
    • RC5
  • Encryption/ Decryption
    • Encryption process
    • Public Key Encryption
    • Symmetric Key Encryption
    • What is Encryption
    • What is Decryption
    • Types of Cipher
    • Transposition Techniques
    • What is Steganography
    • One Time Pad
    • Steganography Techniques
  • Hosting
    • Types of Web Hosting
    • Free Web Hosting Sites
    • What is Hosting
    • What is VPS Hosting
    • What is Web Hosting
    • Types of Domain
    • VPN Applications for PC
    • Why we use VPN?
    • What is Virtual Host?
  • Firewalls
    • What is a Firewall?
    • Types of Firewalls
    • Firewall Devices
    • Firewall Uses
  • Advanced
    • Cryptosystems
    • Configuring DHCP Server
    • Block Cipher modes of Operation
    • TCP/IP Model
    • Types of Network
    • Types of Network Devices
    • Types of Network Topology
    • Types of Intrusion Prevention System
    • Types of Proxy Servers
    • Types of Websites
    • Types of NAT 
    • Mobile IP
    • Career in Automobile Design
    • What is TFS
    • What is NAT
    • What is OSI Model
    • Data Link Layer OSI Model
    • What is Cross Site Scripting
    • Applications of Sensors
    • ARP Packet Format
    • Asymmetric Information
    • Autoencoders
    • What is FTP Server?
    • IPS Tools
    • IPv4 Header Format
    • IPv6 Header Format
    • Authentication Header
    • Kerberos
    • Network Mapper
    • Network Scanning Tools
    • Network Mapping Tools
    • Network Access Control
    • Network Sniffer
    • Networking Commands
    • Networking Devices
    • Networking Strategies
    • Digital Certificate
    • What is a Digital Signature?
    • Digital Signature Softwares
    • Digital Signature Types
    • Digital Signature vs Digital Certificate
    • PKCS
    • What is FTP
    • FTP Commands
    • What is MIME?
    • What is Smart Card?
    • Networking Ports
    • Mutual Authentication
    • Password Authentication
    • Data Masking 
    • Authentication Tokens
    • Biometric Authentication
    • What is IP?
    • IPSec
    • Secure Electronic Transaction
    • What is CIDR
    • Static Binding and Dynamic Binding
    • What is SSL
    • PKIX
    • Public Key Infrastructure
    • What is Wireshark
    • SNMP Monitoring Tools
    • Network Analysis Tools
    • Server Monitoring Tools
    • Network Discovery Tools
    • Network Management Tool
    • SIEM Tools
    • OSINT Tools
    • Multiple Ping Tool
  • Interview Questions
    • Network Security Interview Questions
    • Networking Interview Questions
    • EIGRP Interview Questions

Related Courses

CDN Training

OSPF Certification Training

Penetration Training Course

Footer
About Us
  • Blog
  • Who is EDUCBA?
  • Sign Up
  • Corporate Training
  • Certificate from Top Institutions
  • Contact Us
  • Verifiable Certificate
  • Reviews
  • Terms and Conditions
  • Privacy Policy
  •  
Apps
  • iPhone & iPad
  • Android
Resources
  • Free Courses
  • Java Tutorials
  • Python Tutorials
  • All Tutorials
Certification Courses
  • All Courses
  • Software Development Course - All in One Bundle
  • Become a Python Developer
  • Java Course
  • Become a Selenium Automation Tester
  • Become an IoT Developer
  • ASP.NET Course
  • VB.NET Course
  • PHP Course

© 2020 - EDUCBA. ALL RIGHTS RESERVED. THE CERTIFICATION NAMES ARE THE TRADEMARKS OF THEIR RESPECTIVE OWNERS.

EDUCBA
Free Software Development Course

Web development, programming languages, Software testing & others

*Please provide your correct email id. Login details for this Free course will be emailed to you
Book Your One Instructor : One Learner Free Class

Let’s Get Started

This website or its third-party tools use cookies, which are necessary to its functioning and required to achieve the purposes illustrated in the cookie policy. By closing this banner, scrolling this page, clicking a link or continuing to browse otherwise, you agree to our Privacy Policy

EDUCBA

*Please provide your correct email id. Login details for this Free course will be emailed to you
EDUCBA Login

Forgot Password?

EDUCBA
Free Software Development Course

Web development, programming languages, Software testing & others

*Please provide your correct email id. Login details for this Free course will be emailed to you

Special Offer - All in One Software Development Bundle (600+ Courses, 50+ projects) Learn More