summaryrefslogtreecommitdiff
path: root/sys/src/cmd/ndb/dn.c
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2020-10-17 21:28:25 +0200
committercinap_lenrek <cinap_lenrek@felloff.net>2020-10-17 21:28:25 +0200
commitbf187247380252d3f79ad7089251600b7535815e (patch)
tree96ac2f45e81ad3b1af914bbe2e5cbf68cf1a69a1 /sys/src/cmd/ndb/dn.c
parentd310da13ba8d31c84978f96f542b9929a4e54ed8 (diff)
ndb/dns: mark ns record authoritative when in our area for delegation
I have the problem that i need to delegate a subdomain to another name server that is confused about its own zone (and its own name) returning unusable ns records. With this, one can make up a nameserver entry in ndb that is authoritative and owned by us for that nameserver, and then put it in the soa=delegated ns entry. This promotes the ns record in the soa=delegated to Authoritative, which avoids overriding the ns rr's from the confused server for the delegated zone.
Diffstat (limited to 'sys/src/cmd/ndb/dn.c')
-rw-r--r--sys/src/cmd/ndb/dn.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/src/cmd/ndb/dn.c b/sys/src/cmd/ndb/dn.c
index 71768e7e3..5a789925f 100644
--- a/sys/src/cmd/ndb/dn.c
+++ b/sys/src/cmd/ndb/dn.c
@@ -641,7 +641,8 @@ dnauthdb(void)
if(rp->ttl < minttl)
rp->ttl = minttl;
rp->auth = 1;
- }
+ } else if(rp->type == Tns && inmyarea(rp->host->name))
+ rp->auth = 1;
}
l = &rp->next;
}