[Dnsmasq-discuss] Client Identifier option with dhcp-hostsfile
Sanjiv Doshi (sandoshi)
sandoshi at cisco.com
Mon Oct 10 20:41:21 BST 2016
Folks
We are using dnsmasq with dhcp-hostsfile configured with several <hwaddr>,<ipaddr>,<hostname> tuples.
When I run my udhcpc client on an interface with a MAC address equal to <hwaddr> I get the correct <ipaddr>.
However what I want to do is to match the <hwaddr> with client identifier supplied in the DHCP discover message (using the –x option with opt being 0x3d I.e “-x 0x3d:01aabbccddeeff” in udhcpc).
This does NOT work! Looking at the code it looks like the function that reads the dhcp-hostsfile (dhcp_read_ethers()) does not explicitly support client identifier option (sets the CONFIG_NOCLID flag). As a result find_config() function fails to do a match based on CONFIG_CLID.
So my questions are the following:
* Am I reading this correctly? If not, any suggestions on how to satisfy the above requirements?
* If yes, Is this deliberate as per DHCP standard (Sorry I have not gone through the standard in detail)?
* Specifically, would supporting CONFIG_CLID option create a security hole. Any thoughts? If yes, then shouldn’t “—dhcp-host” option fall into the same category?
Appreciate your help!
Thanks - Sam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20161010/7e64d766/attachment.html>
More information about the Dnsmasq-discuss
mailing list