Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FS#1348 - dnsmasq config script doesn't handle vendorclass specifications properly #6279

Open
openwrt-bot opened this issue Feb 11, 2018 · 0 comments
Labels

Comments

@openwrt-bot
Copy link

cbz:

This happens as of LEDE 17.01.4, and is a result of how /etc/init.d/dnsmasq script rebuilds the temp dnsmasq config file from the /etc/config/dhcp file.

dnsmasq supports the following construct:

dhcp-vendorclass=set:ubiquity,ubnt
dhcp-option=tag:ubiquity,1,192.168.1.10

The meaning of which would be that if a vendor string that matches 'ubnt' is seen, then the class 'ubiquity' is set against the device, any dhcp-options tagged with that class would be sent to devices so tagged.

The dhcp config files supports constructs like this:

config vendorclass 'ubiquity'
option vendorclass 'ubnt'
option networkid 'vendor:ubnt'
list dhcp_option '1,192.168.1.10'

but in this case the value of networkid is pre-pended in each case to the dhcp_option string, like so:

dhcp-vendorclass=vendor:ubnt,ubnt
dhcp-option=vendor:ubnt,1,192.168.1.10

Which works as config - but only because the vendorclass specification is not at work at all - essentially all the matching is occurring within the dhcp-option (it wouldn't be possible to specify multiple values to be matched in the vendorclass specifier for instance).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant