Browse Source

Merge pull request #5374 from EricLuehrsen/unbound_dnsecu

unbound: fix uci for option domain-insecure:
lilik-openwrt-22.03
Hannu Nyman 7 years ago
committed by GitHub
parent
commit
bb089121b3
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 7 deletions
  1. +1
    -1
      net/unbound/Makefile
  2. +16
    -6
      net/unbound/files/unbound.sh

+ 1
- 1
net/unbound/Makefile View File

@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=unbound
PKG_VERSION:=1.6.7
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE


+ 16
- 6
net/unbound/files/unbound.sh View File

@ -60,6 +60,8 @@ UNBOUND_TXT_DOMAIN=lan
UNBOUND_TXT_FWD_ZONE=""
UNBOUND_TXT_HOSTNAME=thisrouter
UNBOUND_LIST_INSECURE=""
##############################################################################
# keep track of local-domain: assignments during inserted resource records
@ -394,7 +396,7 @@ create_access_control() {
##############################################################################
create_domain_insecure() {
echo " domain-insecure: \"$1\"" >> $UNBOUND_CONFFILE
UNBOUND_LIST_INSECURE="$UNBOUND_LIST_INSECURE $1"
}
##############################################################################
@ -568,8 +570,7 @@ unbound_control() {
##############################################################################
unbound_conf() {
local cfg="$1"
local rt_mem rt_conn modulestring
local rt_mem rt_conn modulestring domain
# Make fresh conf file
echo > $UNBOUND_CONFFILE
@ -862,9 +863,15 @@ unbound_conf() {
fi
# Except and accept domains as insecure (DNSSEC); work around broken domains
config_list_foreach "$cfg" "domain_insecure" create_domain_insecure
echo >> $UNBOUND_CONFFILE
if [ -n "$UNBOUND_LIST_INSECURE" ] ; then
for domain in $UNBOUND_LIST_INSECURE ; do
# Except and accept domains without (DNSSEC); work around broken domains
echo " domain-insecure: \"$domain\"" >> $UNBOUND_CONFFILE
done
echo >> $UNBOUND_CONFFILE
fi
}
##############################################################################
@ -1043,6 +1050,8 @@ unbound_uci() {
config_get UNBOUND_TTL_MIN "$cfg" ttl_min 120
config_get UNBOUND_TXT_DOMAIN "$cfg" domain lan
config_list_foreach "$cfg" "domain_insecure" create_domain_insecure
UNBOUND_LIST_DOMAINS="nowhere $UNBOUND_TXT_DOMAIN"
if [ "$UNBOUND_D_DHCP_LINK" = "none" ] ; then
@ -1163,6 +1172,7 @@ unbound_start() {
unbound_access
unbound_adblock
if [ "$UNBOUND_D_DHCP_LINK" = "dnsmasq" ] ; then
dnsmasq_link
else


Loading…
Cancel
Save