- Forward


The Address Resolution Protocol (ARP)
An Introduction


Prof. David Bernstein
James Madison University

Computer Science Department
bernstdh@jmu.edu

Print

Introduction
Back SMYC Forward
  • Purpose:
    • Get the link (or access) layer address (e.g., MAC address) for a given network layer address (e.g., IP address)
  • Why?
    • Suppose an Ethernet host wants to send to another host on the LAN -- it can use DNS to get the IP address of the recipient but then what?
    • Suppose an Ethernet host on LAN 1 wants to send to an Ethernet host on LAN 2 -- it can use DNS to get the IP address of the recipient but how does it get the MAC address of the router?
  • Details:
    • RFC826
ARP Message Contents
Back SMYC Forward
  • The hardware type (e.g., Ethernet)
  • The protocol type (e.g., IPv4)
  • The length of hardware addresses
  • The length of protocol addresses
  • The operation/message type (request or reply)
  • The sender's hardware address
  • The sender's protocol address
  • The target's hardware address (which is ignored for requests)
  • The target's protocol address
The Process
Back SMYC Forward
  1. A check's its ARP table for B's IP address
  2. If B's IP address is not in the table, A broadcasts an ARP request (to ff:ff:ff:ff:ff:ff)
  3. B (or the router, if the IP address is not on the LAN) sends an ARP response to A (and adds A's IP-MAC pair to its ARP table)
  4. A adds the B's information to its ARP table
Gratuitous ARP Messages
Back SMYC Forward
  • What are they?
    • A way for a machine to announce that its IP or MAC address has changed
  • Two Approaches:
    • A request in which the target's protocol address is the same as the sender's protocol address and the target's hardware address is 0
    • A response in which the target's protocol address is the same as the sender's protocol address and the target's hardware address is the same as the sender's hardware address
Reverse Address Resolution Protocol (RARP)
Back SMYC Forward
  • Purpose:
    • Get the network layer address (e.g., IP address) for a given link (or access) layer address (e.g., MAC address)
  • Why?
    • Mostly useful for diskless workstations that have no way to store their IP addresses
  • Details:
    • RFC903
There's Always More to Learn
Back -