commit 3837427189a54e6c052d773d629bac53d95702dc
Author: David Edery <email address hidden>
Date: Mon Oct 12 11:11:50 2015 +0300
Enable specific extra_dhcp_opt to be left blank
In some cases there is a need for a blank value of the "router" extra
dhcp option. This fix addresses this issue by introducing a simple
mechanism in the code that allows specific extra dhcp options to be left
blank by applying a different opt_value validation of the data received
from the REST call and different validation on the value that will be
written to the DB.
This fix also takes into consideration bug #1257467 which claims that
in case of a blank "server-ip-address" option a segmentation fault
occurs in dnsmasq. I did not check this claim with a newer dnsmasq
version since it seemed logical that the list of potentially blank
options should be limited to options that are known to work well when
blank and have functional justification for being blank (e.g. "router")
APIImpact
"router" and "classless-static-route" extra dhcp options can be blank
(e.g. opt-name="router", opt-value="")
DocImpact
During port creation/update, Specific extra-dhcp-options can be left
blank ("router" and/or "classless-static-route"). This causes dnsmasq
to have an empty option in the "opts" file related to the network to
which the port is related.
For example:
tag:tag0,option:classless-static-route,
tag:tag0,option:router,
Reviewed: https:/ /review. openstack. org/229159 /git.openstack. org/cgit/ openstack/ neutron/ commit/ ?id=3837427189a 54e6c052d773d62 9bac53d95702dc
Committed: https:/
Submitter: Jenkins
Branch: master
commit 3837427189a54e6 c052d773d629bac 53d95702dc
Author: David Edery <email address hidden>
Date: Mon Oct 12 11:11:50 2015 +0300
Enable specific extra_dhcp_opt to be left blank
In some cases there is a need for a blank value of the "router" extra
dhcp option. This fix addresses this issue by introducing a simple
mechanism in the code that allows specific extra dhcp options to be left
blank by applying a different opt_value validation of the data received
from the REST call and different validation on the value that will be
written to the DB.
This fix also takes into consideration bug #1257467 which claims that
in case of a blank "server-ip-address" option a segmentation fault
occurs in dnsmasq. I did not check this claim with a newer dnsmasq
version since it seemed logical that the list of potentially blank
options should be limited to options that are known to work well when
blank and have functional justification for being blank (e.g. "router")
APIImpact static- route" extra dhcp options can be blank
"router" and "classless-
(e.g. opt-name="router", opt-value="")
DocImpact static- route") . This causes dnsmasq tag0,option: classless- static- route, tag0,option: router,
During port creation/update, Specific extra-dhcp-options can be left
blank ("router" and/or "classless-
to have an empty option in the "opts" file related to the network to
which the port is related.
For example:
tag:
tag:
Closes-Bug: #1437695
Related-Bug: #1257467
Change-Id: I0ac76e132c4bd8 6da39863674d4cf 8a22dad7034