When will an arp table be updated

arpmac

Will a device's arp table be updated only upon receiving a reply from a previously sent out arp request, or will it be updated if the device receives a frame/packet ?

e.g.
A send a arp request to B
B send a arp reply to A
A's arp table is updated.

or

C sends a packet to A (assuming C already has A's IP/MAC in its arp table)
A's arp table did not have C's entry for some reason
A updates its arp table immediately with C's IP/MAC

Best Answer

The RFC doesn't address your second scenario. The reason for this is that Host C sending to Host A may not be on the same network as Host A. Host A having an ARP cache entry in that case doesn't make sense since Host A will never look for Host C in its ARP cache. Host A will always know Host C is not on its network, so it will always look for its own gateway's entry in its ARP cache when it wants to send to Host C.

There may be implementations that do what you what you describe, but it is not addressed by the standard, and it would seem to waste ARP cache memory.

Related Topic