wire / wire-format / dhcp-protocol

DHCP (Dynamic Host Configuration Protocol)

DHCP automatically assigns IP addresses and network configuration. Process: DISCOVER (client broadcasts), OFFER (server responds with IP), REQUEST (client requests the offered IP), ACK (server confirms). DHCP options: subnet mask (1), router (3), DNS (6), domain name (15), lease time (51), server ID (54), requested IP (50), message type (53). DHCP uses UDP ports 67 (server) and 68 (client).

wire-format kind wire-format status standard verification verified tier B wire-format@1

aka: DHCP (Dynamic Host Configuration Protocol)

wire format

spec: RFC 2131

DHCP automatically assigns IP addresses and network configuration. Process: DISCOVER (client broadcasts), OFFER (server responds with IP), REQUEST (client requests the offered IP), ACK (server confirms). DHCP options: subnet mask (1), router (3), DNS (6), domain name (15), lease time (51), server ID (54), requested IP (50), message type (53). DHCP uses UDP ports 67 (server) and 68 (client).

fieldsizemeaning
DISCOVERbroadcastClient broadcasts DHCPDISCOVER to find servers.
OFFERunicast/broadcastServer responds with DHCPOFFER: offered IP, lease time, options.
REQUESTbroadcastClient broadcasts DHCPREQUEST: accepts the offered IP, rejects others.
ACKunicast/broadcastServer responds with DHCPACK: confirms the IP assignment.
NAKunicast/broadcastServer responds with DHCPNAK: rejects the request (e.g., IP no longer available).
RELEASEunicastClient releases the IP (optional).
DECLINEbroadcastClient declines the IP (e.g., ARP probe found conflict).
OptionsvariableTLV options: type (1 byte), length (1 byte), value. Option 53 = DHCP message type, 1 = subnet mask, 3 = router, 6 = DNS, 15 = domain name, 51 = lease time, 54 = server ID, 50 = requested IP, 255 = end.
Magic cookie4 bytes0x63 0x82 0x53 0x63 (DHCP magic cookie in options field).

example:

00 00 00 00

DHCP (placeholder)


provenance

agent: curl -H 'accept: application/json' wire.phall.io/wire-format/dhcp-protocol or /wire-format/dhcp-protocol.json