In the last post I walked through the building blocks of networking — IP addresses, DNS, ports, subnets, routing, NAT. That post was about the nouns: the things that exist on a network. This one is about the verbs — the actual rulebooks that let two machines that have never met agree on how to talk to each other.

A protocol is a set of rules and message formats that both sides of a connection agree to follow — an internet standard, usually written down in an RFC (Request for Comments) document, that says exactly what a message looks like, what order things happen in, and what each side is supposed to do with what it receives. Your laptop and a server on the other side of the planet have never coordinated with each other directly, but because they both implement the same protocol correctly, they can hold a conversation anyway. That's the entire point.

ARP — Address Resolution Protocol (RFC 826)

ARP solves a very specific, very local problem: on a network segment, IP addresses aren't what devices actually use to deliver data — MAC addresses are. ARP is the mechanism that resolves "I know this device's IP address, what's its MAC address?"

It works with a simple request/response exchange: a device broadcasts an ARP request to the entire local network — "who has this IP address?" — and the device that owns it replies directly with its MAC address. Every device on the segment keeps a local ARP table (a cache of these IP-to-MAC mappings) so it doesn't have to re-ask for every packet.