Discussion:
[Dnsmasq-discuss] [PATCH] allow multiple Classless Route Options
DOB devel
2018-07-10 12:21:56 UTC
Permalink
Hi,
  this patch allows to configure multiple static routes as defined by RFC3442.

Regards
  Sam
 
Simon Kelley
2018-07-19 20:34:51 UTC
Permalink
This generates multiple instance of the DHCP option 121 in the DHCP
reply packet, which isn't strictly legal.

You can include an option 121 with as many routes as you want quite
easily withouyt patching the code.


--dhcp-option=121,127.0.0.1/8,1.2.3.4,192.168.0.0/16,3.4.5.6

Cheers,

Simon.
Post by DOB devel
Hi,
  this patch allows to configure multiple static routes as defined by
RFC3442.
Regards
  Sam
 
_______________________________________________
Dnsmasq-discuss mailing list
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
Roy Marples
2018-07-20 07:55:36 UTC
Permalink
Post by Simon Kelley
This generates multiple instance of the DHCP option 121 in the DHCP
reply packet, which isn't strictly legal.
What makes you think it's not legal?
RFC3442 makes no mention of it not being legal and RFC3396 describes how
multiple instances of options should be concatenated when an options
data exceeds 255 bytes.

dhcpcd of course supports this :)

Roy
Simon Kelley
2018-07-20 16:42:49 UTC
Permalink
Post by Roy Marples
Post by Simon Kelley
This generates multiple instance of the DHCP option 121 in the DHCP
reply packet, which isn't strictly legal.
What makes you think it's not legal?
RFC3442 makes no mention of it not being legal and RFC3396 describes how
multiple instances of options should be concatenated when an options
data exceeds 255 bytes.
dhcpcd of course supports this :)
Roy
You're right, of course :)

However dnsmasq tries not to need this function, on the "be liberal in
what you accept and conservative is what you send" principle.

Perhaps I should have said that dnsmasq doesn't use multiple dhcp-option
lines to construct what it sends for a particular option number. Given
that these things can be tagged, and the semantics for which ones a
valid can get quite complicated, a simplifying rule is that at most one
dhcp-option line is used. That's what the code the OP was patching
actually does, and the patch disabled is as special case for option 121.

The philosophy is that if you need to send multiple values in an option,
then dnsmasq allows you to specify those multiple values in a single
dhcp-option line.



Cheers,

Simon.

Continue reading on narkive:
Loading...