beautypg.com

Dhcp option 82, Protocol details – Allied Telesis x900-48 series User Manual

Page 9

background image

Page 9 | AlliedWare™ OS How To Note: DHCP snooping on AT-9900-style switches

DHCP Option 82 > Protocol details

DHCP Option 82

DHCP Relay Agent Information Option 82 is an extension to the Dynamic Host
Configuration Protocol (DHCP), and is defined in RFC 3046 and RFC 3993.

DHCP Option 82 can be used to send information about DHCP clients to the authenticating
DHCP server. DHCP Option 82 will identify the VLAN number, port number and, optionally
a customer ID of a client, during any IP address allocation. When DHCP Option 82 is enabled
on the switch, it inserts the above information into the DHCP packets as they pass through
the switch on their way to the DHCP server. The DHCP server stores the IP allocation
record.

DHCP Option 82 can work in either layer 2 forwarding or layer 3 routing modes. There are
significant differences in operation and configuration of these two modes – the latter needing
BOOTP Relay support. Some configuration examples and operation descriptions are
provided in a later section of this document.

Although Option 82 is titled the DHCP Relay Agent Information Option, the device that
inserts the Option 82 information into a DHCP packet does not have to be acting as DHCP
relay. A layer 2 switch can insert the Option 82 information into the DHCP packets (if
snooping is enabled). The Option 82 information needs to be inserted into the DHCP
packets by a switch at the edge of the network, because only the edge switch knows the
information that uniquely identifies the subscriber that the IP address was allocated to.

It is quite likely that the edge switch will be a layer 2 switch, rather than a DCHP-relaying
layer 3 switch.

Protocol details

In the DHCP packet, the Option 82 segment is organized as a single DHCP option containing
one or more sub-options that convey information known by the relay agent. The format of
the option is shown below:

Code Len Agent Information Field

+------+------+------+------+------+------+---+------+

| 82 | N | i1 | i2 | i3 | i4 | | iN |

+------+------+------+------+------+------+---+------+

The sub-options within the DHCP option are constructed as follows:

SubOpt Len Sub-option Value

+------+------+------+------+------+------+---+------+

| 1 | N | s1 | s2 | s3 | s4 | | sN |

+------+------+------+------+------+------+---+------+

SubOpt Len Sub-option Value

+------+------+------+------+------+------+---+------+

| 2 | N | i1 | i2 | i3 | i4 | | iN |

+------+------+------+------+------+------+---+------+