Types of Address resolution Protocol(ARP)

Topology

Address resolution Protocol is used to find the Layer 2( mac address) information when the layer 3(IP)

Information is already given. Total 9 filed in Header.

The typical Address resolution protocol Header format is shown as below

Fig1 ARP_Header

Hardware Type: Hardware Type field in the Address Resolution Protocol (ARP) Message specifies the type of hardware used for the local network transmitting the Address Resolution Protocol (ARP) message. Ethernet is the common Hardware Type and the value for Ethernet is 1. The size of this field is 2 bytes.

Protocol Type: Each protocol is assigned a number used in this field. IPv4 is 0x0800.

Hardware Address Length: Hardware Address Length in the Address Resolution Protocol (ARP) Message is length in bytes of a hardware (MAC) address. Ethernet MAC addresses are 6 bytes long.

Protocol Address Length: Length in bytes of a logical address (IPv4 Address). IPv4 addresses are 4 bytes long.

Opcode: Opcode field in the Address Resolution Protocol (ARP) Message specifies the nature of the ARP message. 1 for ARP request and 2 for ARP reply and many more are there.

Sender Hardware Address: Layer 2 (MAC Address) address of the device sending the message.

Sender Protocol Address: The protocol address (IPv4 address) of the device sending the message

Target Hardware Address: Layer 2 (MAC Address) of the intended receiver. This field is ignored in requests. i.e set to 0000:0000:0000

Target Protocol Address: The protocol address (IPv4 Address) of the intended receiver.

Total Field 9.

Learning Acronym HaPur HaPur SSOTT

Types of Address Resolution Protocol (Total 5)

  1. Gratuitous Address Resolution Protocol (GARP)
  2. Address Resolution Protocol (ARP)
  3. Proxy ARP(PARP)
  4. Reverse Address Resolution Protocol (RARP)
  5. Inverse Address Resolution Protocol (iARP)

1.Gratuitous Address Resolution Protocol

This is the very first packet which gets generated when you assigned ip address on the interface and unshut it. Basically, GARP is used to detect the duplicate ip address and Changing of L2 address in case of HSRP/VRRP.

Router IOU1 interface e0/1 has been assigned  with ip address and then unshut the interface. You can see the very first packet sent by IOU1 is GARP , which says if anyone have the same ip do reply to me immediately thus avoid duplicate address assignment on the particular segment.

Header Specification

In GARP header, Source & Ip address are always same. SMAC is the mac of originating interface(Here IOU1 e0/1) & DMAC is FFFF:FFFF:FFFF

Let’s configure IOU1 e0/1 and un shut it

2. Address Resolution Protocol (ARP)

Address resolution protocol is used to discover the Layer 2(MAC) address when Layer 3(IP) address is already known. Its ether-type is 0x0806

Let’s ping PC1 from IOU1 router, PC1 is in router local segment so IOU1 will first perform the AND option to check if the destination IP belong to its own local subnet or not.

Here the PC1 belong to local segment 20.20.20.0 , since the interface is ethernet so router IOU1 must know the Layer 2 address to construct the packet for PC1.

Router IOU1 will first check its ARP table if the PC1 Layer 2 mapping is already present or not.

Here it do not have Layer 2 binding for PC1 in its ARP table. So IOU1 will construct the new ARP packet and send on segment e0/1

Source IP will be IOU1 e0/1(20.20.20.1) & destination IP will be PC1(20.20.20.2).SMAC will be of IOU1 e0/1 interface whereas destination mac will be 00:00:00:00:00:00(IOU1 does not know the mac address of PC1)

Header Specification:

In ARP packet source and destination IPs are different unlike in GARP. The destination MAC is 00:00:00:00:00:00

3. Proxy Address Resolution Protocol (PARP)

Proxy ARP is a technique of fooling the source host by generating the L2 address on behalf of the destination host.

In the figure topology. Router IOU1 is aware about two directly connected network i.e 20.20.20.0 & 50.50.50.0. IOU2 is also aware about two directly connected network i.e

30.30.30.0 & 50.50.50.0.

On a local segment if a host/router want to communicate with the destination subnet it can generate ARP but for remote segment it is not possible that the host originated ARP will reach to destination host.

Here let’s say if PC1(20.20.20.2) want to communicate with PC2(30.30.30.2) which is in different segment.PC1 (20.20.20.2) construct the packet and handover to IOU1. Now IOU1 must know the PC2 30.30.30.2 mac so that I can send the packet to 30.30.30.2, but the destination host 30.30.30.2 is not on the local segment. IOU2 reply with its own mac to reach host 30.30.30.2.

IOU2 will reply with its own mac address on behalf of 30.30.30.2 to IOU1.

In short IOU2 is serving as default L2 gateway for all its local segment. This is how Proxy ARP will work.

Header Specification:

Proxy ARP header specification is same as ARP. Only the difference is Router is generating ARP on behalf of some other network.

4. Reverse Address resolution Protocol (RARP)

Reverse address Resolution protocol is used by client to discover its IP address information.

RARP is obsolete now previously it was in used for DHCP purpose. Now a days we use BOOTP and DHCP for the same purpose. Its ether-type is 0x8035

Header Specification:

RARP packet have SMAC and DMAC same and it the mac of requester(client),Whereas the source & destination ip is 0.0.0.0

5. Inverse Address resolution Protocol (IARP)

Inverse Address Resolution Protocol(iARP) is used in Frame relay for mapping the DLCI to IP address. It is used to find the Layer 3 address from layer 2 (DLCI)

iARP also used in ATM environment. It is opposite of ARP, when ARP is used to get the Layer 2 address when you have layer 3 address, iARP is used to get the layer 3 address when you have Layer 2(DLCI) address.

Header Specification:

iARP have sender and target hardware which is dlci, sender Ip and the destination  is 0.0.0.0

it is just opposite to ARP packet.

Summary:

  1. GARP is used for duplicate address detection and virtual mac change in HSRP/VRRP
  2. GARP packet have same source & destination ip, DMAC is FFFF:FFFF:FFFF
  3. ARP use to discover L2 address when L3 address Is known
  4. ARP packet consists of destination ip address as 0.0.0.0
  5. ARP request is Broadcast , ARP reply is Unicast
  6. PRARP is generated by router on behalf of directly connected subnets.
  7. PARP header is same as ARP
  8. RARP is used to get the L3 address from L2 address.
  9. RARP request packet have same SMAC & DMAC, source & destination ip is 0.0.0.0
  10. iARP is opposite of ARP and is used to get L3 information from L2(DLCI) info.
  11. iARP header have Sender hardware & destination hardware address is DLCI,destination ip is 0.0.0.0
This entry was posted in Routing Protocols and tagged , , , , , , , , , . Bookmark the permalink.