+1959. [func] Control the zeroing of the negative response TTL to
+ a soa query. Defaults "zero-no-soa-ttl yes;" and
+ "zero-no-soa-ttl-cache no;". [RT #15460]
+
1958. [bug] Named failed to update the zone's secure state
until the zone was reloaded. [RT #15412]
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: config.c,v 1.65 2006/01/05 00:01:46 marka Exp $ */
+/* $Id: config.c,v 1.66 2006/01/05 02:19:01 marka Exp $ */
/*! \file */
dnssec-accept-expired no;\n\
clients-per-query 10;\n\
max-clients-per-query 100;\n\
+ zero-no-soa-ttl-cache no;\n\
"
" /* zone */\n\
check-wildcard yes;\n\
check-sibling yes;\n\
check-integrity yes;\n\
+ zero-no-soa-ttl yes;\n\
};\n\
"
- PERFORMANCE OF THIS SOFTWARE.
-->
-<!-- $Id: named.conf.docbook,v 1.17 2006/01/05 00:01:46 marka Exp $ -->
+<!-- $Id: named.conf.docbook,v 1.18 2006/01/05 02:19:01 marka Exp $ -->
<refentry>
<refentryinfo>
<date>Aug 13, 2004</date>
zone-statistics <replaceable>boolean</replaceable>;
key-directory <replaceable>quoted_string</replaceable>;
+ zero-no-soa-ttl <replaceable>boolean</replaceable>;
+ zero-no-soa-ttl-cache <replaceable>boolean</replaceable>;
allow-v6-synthesis { <replaceable>address_match_element</replaceable>; ... }; // obsolete
deallocate-on-exit <replaceable>boolean</replaceable>; // obsolete
zone-statistics <replaceable>boolean</replaceable>;
key-directory <replaceable>quoted_string</replaceable>;
+ zero-no-soa-ttl <replaceable>boolean</replaceable>;
+ zero-no-soa-ttl-cache <replaceable>boolean</replaceable>;
allow-v6-synthesis { <replaceable>address_match_element</replaceable>; ... }; // obsolete
fetch-glue <replaceable>boolean</replaceable>; // obsolete
dialup <replaceable>dialuptype</replaceable>;
ixfr-from-differences <replaceable>boolean</replaceable>;
journal <replaceable>quoted_string</replaceable>;
+ zero-no-soa-ttl <replaceable>boolean</replaceable>;
allow-query { <replaceable>address_match_element</replaceable>; ... };
allow-transfer { <replaceable>address_match_element</replaceable>; ... };
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: query.c,v 1.278 2006/01/04 23:50:24 marka Exp $ */
+/* $Id: query.c,v 1.279 2006/01/05 02:19:01 marka Exp $ */
/*! \file */
* the containing zone of an arbitrary name with a stub
* resolver and not have it cached.
*/
- if (qtype == dns_rdatatype_soa)
+ if (qtype == dns_rdatatype_soa &&
+ dns_zone_getzeronosoattl(zone))
result = query_addsoa(client, db, version, ISC_TRUE);
else
result = query_addsoa(client, db, version, ISC_FALSE);
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: server.c,v 1.454 2006/01/05 00:01:46 marka Exp $ */
+/* $Id: server.c,v 1.455 2006/01/05 02:19:02 marka Exp $ */
/*! \file */
if (lame_ttl > 1800)
lame_ttl = 1800;
dns_resolver_setlamettl(view->resolver, lame_ttl);
+
+ obj = NULL;
+ result = ns_config_get(maps, "zero-no-soa-ttl-cache", &obj);
+ INSIST(result == ISC_R_SUCCESS);
+ dns_resolver_setzeronosoattl(view->resolver, cfg_obj_asboolean(obj));
/*
* Set the resolver's EDNS UDP size.
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: zoneconf.c,v 1.125 2005/11/30 03:33:48 marka Exp $ */
+/* $Id: zoneconf.c,v 1.126 2006/01/05 02:19:02 marka Exp $ */
/*% */
INSIST(result == ISC_R_SUCCESS);
dns_zone_setoption(zone, DNS_ZONEOPT_CHECKSIBLING,
cfg_obj_asboolean(obj));
+
+ obj = NULL;
+ result = ns_config_get(maps, "zero-no-soa-ttl", &obj);
+ INSIST(result == ISC_R_SUCCESS);
+ dns_zone_setzeronosoattl(zone, cfg_obj_asboolean(obj));
}
/*
- PERFORMANCE OF THIS SOFTWARE.
-->
-<!-- File: $Id: Bv9ARM-book.xml,v 1.287 2006/01/05 00:01:46 marka Exp $ -->
+<!-- File: $Id: Bv9ARM-book.xml,v 1.288 2006/01/05 02:19:02 marka Exp $ -->
<book xmlns:xi="http://www.w3.org/2001/XInclude">
<title>BIND 9 Administrator Reference Manual</title>
<optional> empty-contact <replaceable>name</replaceable> ; </optional>
<optional> empty-zones-enable <replaceable>yes_or_no</replaceable> ; </optional>
<optional> disable-empty-zone <replaceable>zone_name</replaceable> ; </optional>
+ <optional> zero-no-soa-ttl <replaceable>yes_or_no</replaceable> ; </optional>
+ <optional> zero-no-soa-ttl-cache <replaceable>yes_or_no</replaceable> ; </optional>
};
</programlisting>
</para>
</listitem>
</varlistentry>
+
+ <varlistentry>
+ <term><command>zero-no-soa-ttl</command><term>
+ <listitem>
+ <para>
+ When returning authoritative negative responses to
+ SOA queries set the TTL of the SOA recored returned in
+ the authority section to zero. Default yes.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><command>zero-no-soa-ttl-cache</command><term>
+ <listitem>
+ <para>
+ When caching a negative response to a SOA query
+ set the TTL to zero. Default no.
+ </para>
+ </listitem>
+ </varlistentry>
</variablelist>
</sect3>
<optional> max-retry-time <replaceable>number</replaceable> ; </optional>
<optional> multi-master <replaceable>yes_or_no</replaceable> ; </optional>
<optional> key-directory <replaceable>path_name</replaceable>; </optional>
+ <optional> zero-no-soa-ttl <replaceable>yes_or_no</replaceable> ; </optional>
}</optional>;
</programlisting>
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><command>zero-no-soa-ttl</command></term>
+ <listitem>
+ <para>
+ See the description of
+ <command>zero-no-soa-ttl</command> in <xref linkend="boolean_options"/>.
+ </para>
+ </listitem>
+ </varlistentry>
+
<varlistentry>
<term><command>database</command></term>
<listitem>
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: resolver.h,v 1.49 2006/01/05 00:01:46 marka Exp $ */
+/* $Id: resolver.h,v 1.50 2006/01/05 02:19:02 marka Exp $ */
#ifndef DNS_RESOLVER_H
#define DNS_RESOLVER_H 1
void
dns_resolver_getclientsperquery(dns_resolver_t *resolver, isc_uint32_t *cur,
isc_uint32_t *min, isc_uint32_t *max);
+
+isc_boolean_t
+dns_resolver_getzeronosoattl(dns_resolver_t *resolver);
+
+void
+dns_resolver_setzeronosoattl(dns_resolver_t *resolver, isc_boolean_t state);
+
ISC_LANG_ENDDECLS
#endif /* DNS_RESOLVER_H */
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: zone.h,v 1.138 2005/10/26 04:35:54 marka Exp $ */
+/* $Id: zone.h,v 1.139 2006/01/05 02:19:02 marka Exp $ */
#ifndef DNS_ZONE_H
#define DNS_ZONE_H 1
isc_boolean_t
dns_zone_getupdatedisabled(dns_zone_t *zone);
+/*%<
+ * Return update disabled.
+ */
void
dns_zone_setupdatedisabled(dns_zone_t *zone, isc_boolean_t state);
+/*%<
+ * Set update disabled.
+ */
+
+isc_boolean_t
+dns_zone_getzeronosoattl(dns_zone_t *zone);
+/*%<
+ * Return zero-no-soa-ttl status.
+ */
+
+void
+dns_zone_setzeronosoattl(dns_zone_t *zone, isc_boolean_t state);
+/*%<
+ * Set zero-no-soa-ttl status.
+ */
void
dns_zone_setchecknames(dns_zone_t *zone, dns_severity_t severity);
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: resolver.c,v 1.325 2006/01/05 00:01:46 marka Exp $ */
+/* $Id: resolver.c,v 1.326 2006/01/05 02:19:02 marka Exp $ */
/*! \file */
unsigned int spillatmax;
unsigned int spillatmin;
isc_timer_t * spillattimer;
+ isc_boolean_t zero_no_soa_ttl;
/* Locked by lock. */
unsigned int references;
isc_boolean_t exiting;
*/
ttl = fctx->res->view->maxncachettl;
if (fctx->type == dns_rdatatype_soa &&
- covers == dns_rdatatype_any)
+ covers == dns_rdatatype_any &&
+ fctx->res->zero_no_soa_ttl)
ttl = 0;
result = ncache_adderesult(fctx->rmessage, fctx->cache, node,
res->spillatmin = res->spillat = 10;
res->spillatmax = 100;
res->spillattimer = NULL;
+ res->zero_no_soa_ttl = ISC_FALSE;
res->nbuckets = ntasks;
res->activebuckets = ntasks;
resolver->spillatmax = max;
UNLOCK(&resolver->lock);
}
+
+isc_boolean_t
+dns_resolver_getzeronosoattl(dns_resolver_t *resolver) {
+ REQUIRE(VALID_RESOLVER(resolver));
+
+ return (resolver->zero_no_soa_ttl);
+}
+
+void
+dns_resolver_setzeronosoattl(dns_resolver_t *resolver, isc_boolean_t state) {
+ REQUIRE(VALID_RESOLVER(resolver));
+
+ resolver->zero_no_soa_ttl = state;
+}
dns_resolver_freeze
dns_resolver_getlamettl
dns_resolver_getudpsize
+dns_resolver_getzeronosoattl
dns_resolver_nrunning
dns_resolver_prime
dns_resolver_reset_algorithms
dns_resolver_setlamettl
dns_resolver_setmustbesecure
dns_resolver_setudpsize
+dns_resolver_setzeronosoattl
dns_resolver_shutdown
dns_resolver_socketmgr
dns_resolver_taskmgr
dns_zone_getxfracl
dns_zone_getxfrsource4
dns_zone_getxfrsource6
+dns_zone_getzeronosoattl
dns_zone_iattach
dns_zone_idetach
dns_zone_isforced
dns_zone_setxfracl
dns_zone_setxfrsource4
dns_zone_setxfrsource6
+dns_zone_setzeronosoattl
dns_zone_unload
dns_zonekey_iszonekey
dns_zonemgr_attach
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: zone.c,v 1.448 2006/01/04 00:37:24 marka Exp $ */
+/* $Id: zone.c,v 1.449 2006/01/05 02:19:02 marka Exp $ */
/*! \file */
dns_acl_t *query_acl;
dns_acl_t *xfr_acl;
isc_boolean_t update_disabled;
+ isc_boolean_t zero_no_soa_ttl;
dns_severity_t check_names;
ISC_LIST(dns_notify_t) notifies;
dns_request_t *request;
zone->query_acl = NULL;
zone->xfr_acl = NULL;
zone->update_disabled = ISC_FALSE;
+ zone->zero_no_soa_ttl = ISC_TRUE;
zone->check_names = dns_severity_ignore;
zone->request = NULL;
zone->lctx = NULL;
zone->update_disabled = state;
}
+isc_boolean_t
+dns_zone_getzeronosoattl(dns_zone_t *zone) {
+ REQUIRE(DNS_ZONE_VALID(zone));
+ return (zone->zero_no_soa_ttl);
+
+}
+
+void
+dns_zone_setzeronosoattl(dns_zone_t *zone, isc_boolean_t state) {
+ REQUIRE(DNS_ZONE_VALID(zone));
+ zone->zero_no_soa_ttl = state;
+}
+
void
dns_zone_setchecknames(dns_zone_t *zone, dns_severity_t severity) {
return (zone->keydirectory);
}
+
unsigned int
dns_zonemgr_getcount(dns_zonemgr_t *zmgr, int state) {
dns_zone_t *zone;
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: namedconf.c,v 1.61 2006/01/05 00:01:46 marka Exp $ */
+/* $Id: namedconf.c,v 1.62 2006/01/05 02:19:02 marka Exp $ */
/*! \file */
{ "empty-contact", &cfg_type_astring, 0 },
{ "empty-zones-enable", &cfg_type_boolean, 0 },
{ "disable-empty-zone", &cfg_type_astring, CFG_CLAUSEFLAG_MULTI },
+ { "zero-no-soa-ttl-cache", &cfg_type_boolean, 0 },
{ NULL, NULL, 0 }
};
{ "check-integrity", &cfg_type_boolean, 0 },
{ "check-mx", &cfg_type_checkmode, 0 },
{ "check-sibling", &cfg_type_boolean, 0 },
+ { "zero-no-soa-ttl", &cfg_type_boolean, 0 },
{ NULL, NULL, 0 }
};