summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2014-09-04 09:40:34 +0200
committerKarolin Seeger <kseeger@samba.org>2014-09-08 07:49:09 +0200
commit748e78eb6d64ba48a729e67fedb2614b39d79ff8 (patch)
tree3f7008056f26c38f002b61f1c89712171fde47fa /source4
parentc371cadfa8f0555c8243e4ace7df1c0a58b9d326 (diff)
downloadsamba-748e78eb6d64ba48a729e67fedb2614b39d79ff8.tar.gz
s4-rpc: dnsserver: return DNS_RANK_NS_GLUE recors when explicitly asked for
NS records should be included in the query for sub-domains. NS records got dropped when the rank for NS records was correctly set to NS_GLUE from ZONE in commit 2036cbd9249c84d9b46370f0e8cd6a0264c737ba. samba-tool dns query 172.31.9.161 s4xdom.base @ ALL => Name=glue, Records=0, Children=0 samba-tool dns query 172.31.9.161 s4xdom.base glue ALL => Name=, Records=1, Children=0 NS: glue.dns.private. (flags=40000082, serial=21, ttl=900) Bug: https://bugzilla.samba.org/show_bug.cgi?id=10751 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Amitay Isaacs <amitay@gmail.com> Autobuild-User(master): Amitay Isaacs <amitay@samba.org> Autobuild-Date(master): Thu Sep 4 14:37:51 CEST 2014 on sn-devel-104 (cherry picked from commit 0b4a3b76111411e8969932a3da4ffab989e0da4c)
Diffstat (limited to 'source4')
-rw-r--r--source4/rpc_server/dnsserver/dnsdata.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/source4/rpc_server/dnsserver/dnsdata.c b/source4/rpc_server/dnsserver/dnsdata.c
index 4866006cdf9..f752490101a 100644
--- a/source4/rpc_server/dnsserver/dnsdata.c
+++ b/source4/rpc_server/dnsserver/dnsdata.c
@@ -798,6 +798,15 @@ WERROR dns_fill_records_array(TALLOC_CTX *mem_ctx,
if (select_flag & DNS_RPC_VIEW_AUTHORITY_DATA) {
if (dnsp_rec.rank == DNS_RANK_ZONE) {
found = true;
+ } else if (dnsp_rec.rank == DNS_RANK_NS_GLUE) {
+ /*
+ * If branch_name is NULL, we're
+ * explicitly asked to also return
+ * DNS_RANK_NS_GLUE records
+ */
+ if (branch_name == NULL) {
+ found = true;
+ }
}
}
if (select_flag & DNS_RPC_VIEW_CACHE_DATA) {