]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
[master] allow 1-week nta-lifetime/nta-recheck
authorEvan Hunt <each@isc.org>
Mon, 20 Oct 2014 20:40:17 +0000 (13:40 -0700)
committerEvan Hunt <each@isc.org>
Mon, 20 Oct 2014 20:40:17 +0000 (13:40 -0700)
3983. [bug] Change #3940 was incomplete: negative trust anchors
could be set to last up to a week, but the
"nta-lifetime" and "nta-recheck" options were
still limted to one day. [RT #37522]

CHANGES
bin/tests/system/checkconf/bad-lifetime.conf [new file with mode: 0644]
bin/tests/system/checkconf/good.conf
bin/tests/system/checkconf/tests.sh
doc/arm/Bv9ARM-book.xml
lib/bind9/check.c

diff --git a/CHANGES b/CHANGES
index 0bce3631da44e32bfad556bd4f0cf87cd0c9449a..c3a8615f07a4e0db3943f4df3f563d89da4fb5a2 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,8 @@
+3983.  [bug]           Change #3940 was incomplete: negative trust anchors
+                       could be set to last up to a week, but the
+                       "nta-lifetime" and "nta-recheck" options were
+                       still limted to one day. [RT #37522]
+
 3982.  [doc]           Include release notes in product documentation.
                        [RT #37272]
 
diff --git a/bin/tests/system/checkconf/bad-lifetime.conf b/bin/tests/system/checkconf/bad-lifetime.conf
new file mode 100644 (file)
index 0000000..d1be9f1
--- /dev/null
@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2014  Internet Systems Consortium, Inc. ("ISC")
+ *
+ * Permission to use, copy, modify, and/or distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
+ * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+ * AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
+ * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
+ * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+ * PERFORMANCE OF THIS SOFTWARE.
+ */
+
+options {
+       nta-lifetime 8d;
+};
index d14ccd858094644a4b225309b102b1a04eb97df9..f1cb142996363044a4378a9fe75a8ba9fd2cfb82 100644 (file)
@@ -66,6 +66,8 @@ options {
        serial-query-rate 100;
        server-id none;
        max-cache-size 20000000000000;
+       nta-recheck 604800;
+       nta-lifetime 604800;
        transfer-source 0.0.0.0 dscp 63;
        zone-statistics none;
 };
index 4e4f4da7018f15c528b77a2d9f2db2a3fedf42e2..69cd2b63d534b20f40c2306b8a6b1230afbecd80 100644 (file)
@@ -12,8 +12,6 @@
 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 # PERFORMANCE OF THIS SOFTWARE.
 
-# $Id$
-
 SYSTEMTESTTOP=..
 . $SYSTEMTESTTOP/conf.sh
 
index 7331b1d65d590620389a4890ac8e9c9c61a7fdc5..34a9f97a7a68c2741d5930cad654df221f8f9d8f 100644 (file)
@@ -5770,7 +5770,9 @@ options {
                <para>
                  For convenience, TTL-style time unit suffixes can be
                  used to specify the NTA recheck interval in seconds,
-                 minutes or hours.  The default is five minutes.
+                 minutes or hours.  The default is five minutes.  It
+                 cannot be longer than <option>nta-lifetime</option>
+                 (which cannot be longer than a week).
                </para>
            </listitem>
          </varlistentry>
index 58668ae58b1bf67552ee1d019fb5e367dbb83594..d0029e49a43662459d9243d58ebd4663f85ee1af 100644 (file)
@@ -1176,9 +1176,9 @@ check_options(const cfg_obj_t *options, isc_log_t *logctx, isc_mem_t *mctx,
        (void)cfg_map_get(options, "nta-lifetime", &obj);
        if (obj != NULL) {
                lifetime = cfg_obj_asuint32(obj);
-               if (lifetime > 86400) {
+               if (lifetime > 604800) {        /* 7 days */
                        cfg_obj_log(obj, logctx, ISC_LOG_ERROR,
-                                   "'nta-lifetime' cannot exceed one day");
+                                   "'nta-lifetime' cannot exceed one week");
                        result = ISC_R_RANGE;
                } else if (lifetime == 0) {
                        cfg_obj_log(obj, logctx, ISC_LOG_ERROR,
@@ -1191,9 +1191,9 @@ check_options(const cfg_obj_t *options, isc_log_t *logctx, isc_mem_t *mctx,
        (void)cfg_map_get(options, "nta-recheck", &obj);
        if (obj != NULL) {
                isc_uint32_t recheck = cfg_obj_asuint32(obj);
-               if (recheck > 86400) {
+               if (recheck > 604800) {         /* 7 days */
                        cfg_obj_log(obj, logctx, ISC_LOG_ERROR,
-                                   "'nta-recheck' cannot exceed one day");
+                                   "'nta-recheck' cannot exceed one week");
                        result = ISC_R_RANGE;
                }