Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Dynamic Host Configuration Protocol
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
===Discovery=== The DHCP client [[Broadcasting (networking)|broadcasts]] a DHCPDISCOVER message on the network subnet using the destination address {{IPaddr|255.255.255.255}} (limited broadcast) or the specific subnet broadcast address (directed broadcast). A DHCP client may also request an IP address in the DHCPDISCOVER, which the server may take into account when selecting an address to offer. For example, if HTYPE is set to 1, to specify that the medium used is [[Ethernet]], HLEN is set to 6 because an Ethernet address (MAC address) is 6 octets long. The CHADDR is set to the MAC address used by the client. Some options are set as well. {{APHD|start|title=Example Ethernet frame with a DHCPDISCOVER message}} {{APHD|0|bits1=32|border1=bottom|field1=Source MAC|value1={{MACaddr|00:05:3c:04:8d:59}}}} {{APHD|4|bits1=16|border1=top|field1={{nbsp}}|bits2=16|border2=bottom|field2={{nbsp}}}} {{APHD|8|bits1=32|border1=top|field1=Destination MAC|value1={{MACaddr|ff:ff:ff:ff:ff:ff}}}} {{APHD|12|bits1=16|field1=EtherType|value1={{Mono|0x0800}}|hint1=0x0800 indicates IPv4|bits2=16|border2=bottom|background2=mistyrose|field2={{nbsp}}}} {{APHD|16|bits1=0|border1=top|background1=mistyrose|field1=IPv4 packet, containing a UDP PDU with DHCP payload...}} {{APHD|999|bits1=32|field1=Frame Check Sequence|short1=FCS}} {{APHD|end}} {{APHD|start|header=yew|title=IPv4 Header}} {{APHD|0|bits1=64|field1=IPv4 header start}} {{APHD|8|bits1=8|bits2=8|bits3=16|field1=TTL|field2=Protocol|value2={{Mono|17}} UDP|field3=Header Checksum}} {{APHD|end}} {{APHD|start|header=no|title=UDP Header}} {{APHD|12|bits1=32|field1=Source Address|value1={{IPaddr|0.0.0.0}}}} {{APHD|16|bits1=32|field1=Destination Address|value11={{IPaddr|255.255.255.255}}}} {{APHD|20|bits1=16|bits2=16|field1=Source Port|value1=68|field2=Destination Port|value2=67}} {{APHD|24|bits1=16|bits2=16|field1=Length|field2=Checksum}} {{APHD|end}} {{APHD|start|header=no|title=DHCP Payload: DHCPDISCOVER}} {{APHD|28|bits1=8|bits2=8|bits3=8|bits4=8|field1=OP|value1={{Mono|0x01}}|hint1=BOOTREQUEST|field2=HTYPE|value2={{Mono|0x01}}|hint2=Ethernet|field3=HLEN|value3={{Mono|0x06}}|hint3=MAC addresses are 6 octets|field4=HOPS|value4={{Mono|0x00}}}} {{APHD|32|bits1=32|field1=XID|value1={{Mono|0x3903F326}}}} {{APHD|36|bits1=16|bits2=16|field1=SECS|value1={{Mono|0x0000}}|field2=FLAGS|value2={{Mono|0x0000}}}} {{APHD|40|bits1=32|field1=CIADDR|value1=Client IP address: {{Mono|0x00000000}}}} {{APHD|44|bits1=32|field1=YIADDR| value1=Your IP address: {{Mono|0x00000000}}}} {{APHD|48|bits1=32|field1=SIADDR|value1=Server IP address: {{Mono|0x00000000}}}} {{APHD|52|bits1=32|field1=GIADDR|value1=Gateway IP address: {{Mono|0x00000000}}|hint1=A zero GIADDR means client and DHCP server are on the same subnet.}} {{APHD|56|bits1=128|field1=CHADDR|value1=Client Hardware address: {{Mono|0x00053C04<br>0x8D590000<br>0x00000000<br>0x00000000}}}} {{APHD|72|bits1=1536|field1=192 octets of 0s, or overflow space for additional options; BOOTP legacy.}} {{APHD|264|bits1=32|field1=[[Magic Cookie]]|value1={{Mono|0x63825363}}}} {{APHD|end}} {{APHD|start|header=no|title=DHCP Options (in [[Type-length-value|TLV]] format)}} {{APHD|268|bits1=24|background1=linen|field1=First option: {{Mono|0x350101}}: Option 53 (DHCP Message Type) 1 octet (containing DHCPDISCOVER)|bits2=8|background2=linen|border2=right|field2=Second option:}} {{APHD|272|bits1=32|background1=linen|border1=left|field1={{Mono|0x3204c0a80164}}: Option 50 (Request IP address) 4 octets (containing {{IPaddr|192.168.1.100}})}} {{APHD|276|bits1=32|background1=linen|field1=Third option: {{Mono|0x370401030f06}}: Option: 55 (Parameter Request List) 4 octets|hint1=0x01: Request Subnet Mask; 0x03: Router; 0x0f: Domain Name|border1=right}} {{APHD|280|bits1=8|background1=linen|border1=left|field1=PRL cont...|hint1=0x06: Domain Name Server|bits2=1|field2=<small>{{Mono|ff}}</small>|hint2=0xff Option end mark}} {{APHD|end}}
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)