ARP used to map IP address to MAC address on data link layer. It mainly used when Host is connected over Ethernet.
In long explanation,
If you have used wireshark, maybe you can remember on Info section, there are always message saying "Who has $IP". For example:

Situation where ARP is used.
Reference:
In long explanation,
- This protocol used to locate address of a Host (Physical/Virtual) in network.
- The address is searched or "resolved" by sending an "information" to a server (other host).
- The server after received the information will then identify itself and respond back with the network information.
- The responded information contain the required address.
- This always happen over Ethernet.
- Ethernet address dependent to the hardware which is Network Interface card.
- So, during ARP request, it try to ask which IP associated with which MAC address.
If you have used wireshark, maybe you can remember on Info section, there are always message saying "Who has $IP". For example:
Situation where ARP is used.
- Someone with IP X.X.X.X try ping $IP = Y.Y.Y.Y. We assume, the source PC did not have the IP information from the Target PC.
So it will try to use ARP to identify the MAC address of the Target PC. - On Source PC, It will sent an ICMP echo request packet.
- Unfortunately because it did not have the complete information of the Target PC, it is then broadcast the network with a ARP Request contain message "Who has Y.Y.Y.Y, please tell X.X.X.X".
Example of ARP Request in figure below: - Note that since this request is broadcasted, all host connected in the network will receive the ARP request message.
- Somehow somewhere in the network, the Target PC receive this message. It will then respond to the message. Note that other PC will discard this message if it does not associated with the address in the request.
- Target PC will then reply with ARP Reply message contain message "Y.Y.Y.Y is at $Target" whereby $Target is the MAC address of the Network Interface hardware in Target PC.
Example of ARP Reply in figure below: - ICMP packet is then ready until source PC receive the Target PC's MAC address.
- ICMP packet is sent to the Target PC.
- Target PC replies to Source PC.
Reference:
- https://erg.abdn.ac.uk/users/gorry/course/inet-pages/arp.html
- http://www.omnisecu.com/tcpip/address-resolution-protocol-arp.php
Comments
Post a Comment