The situation in which long lists of items are carried in an option leads to the second special
case. Suppose the collection of options being sent in a DHCP message exceeds the default
maximum options section size of 312 bytes. In anticipation of this problem, DHCP enables
redefinition of the sname and file fields from the fixed-format section of the DHCP
message to hold options rather than a server name and configuration file name. Using the
two fields from the fixed-format section allows for 192 additional bytes of options, an
increase of more than 60%.
Design Constraints
One might look at the format of a DHCP message and ask, “How did anyone come
up with this format?” In the right situation, Ralph Droms, who is one of the authors
of this book and was part of the initial DHCP design process, might be persuaded to
admit that the DHCP message format is, indeed, arcane and bordering on ugly. The
primary constraint around which the DHCP message format was designed is back-
ward compatibility with BOOTP messages. When the design choices were made (in
1990–1991), some router vendors were including BOOTP relay agents in their prod-
ucts. The DHCP designers retained the original BOOTP format for DHCP in order to
leverage the availability of these BOOTP relay agents and allow for easy DHCP
deployment. To ensure that the BOOTP relay agents would correctly forward DHCP
messages, the BOOTP format was retained. Rather than encode new DHCP functions
in the
op field (which might have caused deployed BOOTP relay agents to reject the
message), the DHCP functions were encoded as options (which BOOTP relay agents
never touch).
DHCP messages differ from BOOTP messages in four important ways:
• DHCP messages include a
flags field, which is in an area defined as “unused”
by the BOOTP specification. The definition of the
flags came about as an engi-
neering solution (or workaround) for certain TCP/IP stacks; Chapter 7 explains
the details of the
flags field.
• DHCP allows the options section (called the vendor extensions field in
BOOTP) to be at least 312 bytes long, whereas BOOTP allows only 64 bytes of
options.
• The
DHCP message type option identifies DHCP messages.
• The sname and file fields in a DHCP message can be used to hold additional
options.
DHCP also retains the format of options, originally defined in RFC 1048, and the
convention of reserving option codes 128–254 for local use. Therefore, a network
architect can safely use the local-use options without conflicting with standard
CHAPTER 6 The Format of DHCP Messages80
009 3273 CH06 10/3/02 5:01 PM Page 80