From: Mark Andrews Date: Thu, 26 Nov 2009 03:40:20 +0000 (+0000) Subject: 2790. [bug] Handle DS queries to stub zones. X-Git-Tag: v9.5.2-P1~1^8~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e7a35d4e83d7fde6b821b6209bf2f1609a2a1423;p=thirdparty%2Fbind9.git 2790. [bug] Handle DS queries to stub zones. --- diff --git a/CHANGES b/CHANGES index 2c92d268a4e..f68ed9ab466 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,5 @@ +2790. [bug] Handle DS queries to stub zones. + 2786. [bug] Additional could be promoted to answer. [RT #20663] 2784. [bug] TC was not always being set when required glue was diff --git a/lib/dns/rbtdb.c b/lib/dns/rbtdb.c index 4ad10881a50..6e02c2fb2a8 100644 --- a/lib/dns/rbtdb.c +++ b/lib/dns/rbtdb.c @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: rbtdb.c,v 1.248.12.20 2009/11/25 02:32:05 marka Exp $ */ +/* $Id: rbtdb.c,v 1.248.12.21 2009/11/26 03:40:20 marka Exp $ */ /*! \file */ @@ -3097,12 +3097,18 @@ zone_find(dns_db_t *db, dns_name_t *name, dns_dbversion_t *version, } else { /* * The node may be a zone cut itself. If it might be one, - * make sure we check for it later. + * make sure we check for it later. + * + * DS records live above the zone cut in ordinary zone so + * we want to ignore any referral. + * + * Stub zones don't have anything "above" the delgation so + * we always return a referral. */ if (node->find_callback && - (node != search.rbtdb->origin_node || - IS_STUB(search.rbtdb)) && - !dns_rdatatype_atparent(type)) + ((node != search.rbtdb->origin_node && + !dns_rdatatype_atparent(type)) || + IS_STUB(search.rbtdb))) maybe_zonecut = ISC_TRUE; }