comp.org.uk

Networking | Programming | Security | Linux | Computer Science | About

Explanation of the Address Resolution Protocol

Address Resolution Protocol [ARP] is a network layer protocol that is used to convert IP address into MAC address. Network interface cards (NICs) each have a hardware address or MAC address associated with them. Applications understand TCP/IP addressing, but network hardware devices (such as NICs) do not.

For example, when two Ethernet cards are communicating, they have no knowledge of the IP address being used. Instead, they use the MAC addresses assigned to each card to address data frames. The ARP was designed to provide a mapping from the logical 32-bit TCP/IP addresses to the physical 48-bit MAC addresses.

ARP resolves IP addresses used by TCP/IP-based software to media access control addresses used by LAN hardware.

Why do we need Address Resolution Protocol [ARP]?

An Internet is made of a combination of physical networks connected together by internetworking devices such as routers and gateways. A packet starting from a source host may pass through different physical networks before finally reaching the destination host.

The hosts and routers are recognized at the network level by their logical addresses. A logical address is an Internetwork address. A logical address is unique universally. It is called a logical address because it is usually implemented in software. Every protocol that deals with interconnecting networks requires logical addresses. The logical addresses in the TCP/IP protocol suite are called IP addresses and are 32 bits long. However, packets pass through physical networks to reach these hosts and routers. At the physical level, the hosts and routers are recognized by their physical addresses. A physical address is a local address. Its scope is a local network. It should be unique locally, but not necessary universally. It is called a physical address because it is usually (not always) implemented in hardware. Examples of physical addresses are 48 bit MAC addresses in Ethernet and token ring protocols, which are imprinted on the NIC installed in the host or router.

The physical and logical addresses are two different identifiers. We need both of them because a physical network, such as an Ethernet can be used by two different protocols at the network layer such as IP and IPX (Novell) at the same time. Likewise, a packet at the network layer such as IP may pass through different physical networks such as Ethernet and LocalTalk.

This means that delivery of a packet to a host or a router requires two levels of addressing: logical and physical.

The main issue is that IP datagrams contain IP addresses, but the physical interface hardware on the host or router to which we want to send the datagram only understands the addressing scheme of that particular network.


Published on Sat 24 July 2010 by Phil Helmsley in Networking with tag(s): arp