Feature Request: [odhcpd] Add Vendor-Specific Information option (RFC 3925/9915)

Kevin Vigouroux kevin.vigouroux at dizog.info
Fri Sep 25 02:27:54 PDT 2026


Hi!

I would have liked to include the DHCP Vendor-Specific Information option in
odhcpd (DHCPv4 125 and DHCPv6 17).

#+BEGIN_EXAMPLE
package dhcp

config vendor_option
    option vendor 'orange'
    option id 'dhcpv4 1368 1 txt'
    option info 'Livebox Fibre'

config vendor_option
    option vendor 'Broadband Forums'
    option id 'dualstack 3561 4 txt'
    option info 'SMBS02C3D435'

config vendor_option
    option vendor 'orange'
    option id 'dhcpv6 1368 1 hex'
    option info '00:01:00:00:00:00:00:00:00:00'

...
#+END_EXAMPLE

I think I'm almost done implementing the feature. There's probably less than 10
percent of the work left to do.

I've pretty much serialized the options by vendor. All that's left is to
integrate them into DHCPv4 and DHCPv6. But I'm facing a dilemma. 

I’m not sure whether I should support selection by vendor class, or statically
by interface, or possibly by host.

I can use libubox’s AVL tree to select a vendor by its enterprise number, or I
can traverse all the nodes in the tree using avl_for_each_entry() and compare
the defined vendor names.

#+BEGIN_EXAMPLE
package network

config interface 'lan'
    list vendor_options 'orange'
    list vendor_options 'Broadband Forums'
...
#+END_EXAMPLE

I'm asking this to find out if the option named "vendor" in the "vendor_option"
section is useful. Otherwise, I could simplify it. Currently, the vendor name
and the enterprise number correspond one-to-one (bijection).

The implementation of this feature in prplos does not comply with RFC 9915.
See below.

https://gitlab.com/prpl-foundation/mirrors/odhcpd/-/commit/17014fd2a6535e3ab8978a3b6bfb492238e1c404

It should be possible to create multiple vendor instances in the same DHCP
message. In addition, in their implementation, you can specify information for
only one vendor per interface (e.g. subnet). My implementation is much more
complex (~ 900 lines of code).

I'm feeling a little discouraged. Please feel free to ask me any questions so I
can be sure I did everything right. I haven't posted my source code because it's
not finished but I can post it on Codeberg.

--
Best regards,
Kevin Vigouroux




More information about the openwrt-devel mailing list