openwrt/package/network/services/dnsmasq/files
Thibaut VARÈNE 8815a3114f dnsmasq: invert logic for "localuse"
Prior to this commit, "localuse" (which enables local resolving through
dnsmsasq) was off by "default". That default was in turn overridden when
"noresolv" was unset (which itself is the default for "noresolv") *and*
"resolvfile" was "/tmp/resolv.conf.d/resolv.conf.auto" (also the default
for this parameter).

In other words, the "default" unset value for "localuse" would only be
ever used in specific *non-default* configurations.

However, the problem with that logic is that a user who wants to ignore
their ISP-provided resolvers by setting "noresolv" to true ends up with
a device that will *only use* said resolvers for local DNS queries,
serving clients' queries via dnsmasq (which now ignores the ISP
resolvers). This can lead to confusion and break random setups as the
DNS lookup performed on clients behalf can differ in their replies from
DNS lookups performed locally on the router.

Furthermore, "localuse" is not configurable through Luci, contrary to
the other two involved settings, adding further confusion for the end
user.

To work around this situation, the logic that sets "localuse" is
inverted: "localuse" now defaults to on by default, and IFF "noresolv"
is unset (default) AND "resolvfile" is changed from default THEN
"localuse" gets turned back off, allowing for more sensible behaviour.

"localuse" value set in config/dhcp still overrides the logic in all
cases, as it did already.

Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
2023-12-16 15:28:21 +00:00
..
50-dnsmasq-migrate-ipset.sh dnsmasq: add uci-defaults script for ipset migration 2022-11-06 19:47:13 +00:00
50-dnsmasq-migrate-resolv-conf-auto.sh dnsmasq: fix uci-defaults script to exit 0 so it is cleaned up 2020-02-19 22:02:59 +01:00
dhcp-script.sh dnsmasq: switch to ubus-based hotplug call 2021-02-08 00:57:14 +00:00
dhcp.conf dnsmasq: set an increased cachesize default value 2023-01-21 11:13:44 +01:00
dhcpbogushostname.conf dnsmasq: add dhcp-ignore-names support - CERT VU#598349 2018-10-09 09:45:16 +01:00
dnsmasq_acl.json dnsmasq: add ubus acl to allow calls to hotplug.tftp object 2021-11-12 15:02:58 +00:00
dnsmasq.conf packages: sort network related packages into package/network/ 2012-10-10 12:32:29 +00:00
dnsmasq.init dnsmasq: invert logic for "localuse" 2023-12-16 15:28:21 +00:00
dnsmasqsec.hotplug dnsmasq: switch to ubus-based hotplug call 2021-02-08 00:57:14 +00:00
rfc6761.conf dnsmasq: remove example domains from rfc6761.conf (FS#1447) 2018-04-09 17:35:17 +02:00