]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
3200. [doc] Some rndc functions were undocumented or were
authorEvan Hunt <each@isc.org>
Thu, 3 Nov 2011 22:06:21 +0000 (22:06 +0000)
committerEvan Hunt <each@isc.org>
Thu, 3 Nov 2011 22:06:21 +0000 (22:06 +0000)
missing from 'rndc -h' output. [RT #25555]

CHANGES
bin/rndc/rndc.c
bin/tests/system/tkey/clean.sh
bin/tests/system/tkey/ns1/named.conf.in
bin/tests/system/tkey/tests.sh
doc/arm/Bv9ARM-book.xml

diff --git a/CHANGES b/CHANGES
index 09245a09e46bff116fbe7ad0aa853ca810a25f09..c82fef2310fa4f3ffcbf3060893973adbd6d7174 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,6 @@
+3200.  [doc]           Some rndc functions were undocumented or were
+                       missing from 'rndc -h' output. [RT #25555]
+
 3199.  [func]          When logging client information, include the name
                        being queried. [RT #25944]
 
index 75f9328222a0ec938101c99e1e6b4bc11903ee1e..17583252ef32ceb0a99e40e312f989fad9aea215 100644 (file)
@@ -15,7 +15,7 @@
  * PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: rndc.c,v 1.136 2011/10/28 06:20:05 each Exp $ */
+/* $Id: rndc.c,v 1.137 2011/11/03 22:06:21 each Exp $ */
 
 /*! \file */
 
@@ -145,11 +145,16 @@ command is one of the following:\n\
   flush [view] Flushes the server's cache for a view.\n\
   flushname name [view]\n\
                Flush the given name from the server's cache(s)\n\
+  flushtree name [view]\n\
+               Flush all names under the given name from the server's cache(s)\n\
   status       Display status of the server.\n\
   recursing    Dump the queries that are currently recursing (named.recursing)\n\
+  tsig-list    List all currently active TSIG keys, including both statically\n\
+               configured and TKEY-negotiated keys.\n\
+  tsig-delete keyname [view]   \n\
+               Delete a TKEY-negotiated TSIG key.\n\
   validation newstate [view]\n\
                Enable / disable DNSSEC validation.\n\
-  *restart     Restart the server.\n\
   addzone [\"file\"] zone [class [view]] { zone-options }\n\
                Add zone to given view. Requires new-zone-file option.\n\
   delzone [\"file\"] zone [class [view]]\n\
@@ -163,6 +168,7 @@ command is one of the following:\n\
   signing -clear all zone [class [view]]\n\
                Remove the private records for all keys that have\n\
                finished signing the given zone.\n\
+  *restart     Restart the server.\n\
 \n\
 * == not yet implemented\n\
 Version: %s\n",
index 7d64de5c9bba8231d92cc4ed5427a520ecf72ece..57ef956754467ce686953345337210f3827d38e0 100644 (file)
@@ -15,8 +15,9 @@
 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 # PERFORMANCE OF THIS SOFTWARE.
 
-# $Id: clean.sh,v 1.6 2007/09/26 03:22:44 marka Exp $
+# $Id: clean.sh,v 1.7 2011/11/03 22:06:21 each Exp $
 
 rm -f dig.out.* random.data ns1/named.conf
 rm -f K* ns1/K*
 rm -f */named.memstats
+rm -f rndc.out
index 5de2e418592af214d9300ebfb54afa7d7376f5b3..5452b826d2e69e86c577f5cd0507ebb2b45ed43b 100644 (file)
@@ -15,7 +15,7 @@
  * PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: named.conf.in,v 1.8 2009/01/30 23:47:50 tbox Exp $ */
+/* $Id: named.conf.in,v 1.9 2011/11/03 22:06:21 each Exp $ */
 
 controls { /* empty */ };
 
@@ -34,6 +34,15 @@ options {
        allow-query-cache { any; };
 };
 
+key rndc_key {
+        secret "1234abcd8765";
+        algorithm hmac-md5;
+};
+
+controls {
+        inet 10.53.0.1 port 9953 allow { any; } keys { rndc_key; };
+};
+
 key "tkeytest." {
        algorithm hmac-md5;
        secret "0123456789ab";
index d9dd3ec77dbab236d7c98bf97d56639604398594..c9d98c41c6d3a7e9c4b0dd7f665d47e31501b930 100644 (file)
@@ -15,7 +15,7 @@
 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 # PERFORMANCE OF THIS SOFTWARE.
 
-# $Id: tests.sh,v 1.9 2009/07/19 23:47:55 tbox Exp $
+# $Id: tests.sh,v 1.10 2011/11/03 22:06:21 each Exp $
 
 SYSTEMTESTTOP=..
 . $SYSTEMTESTTOP/conf.sh
@@ -79,5 +79,34 @@ do
        status=`expr $status + $ret`
 done
 
+echo "I:creating new key using owner name bar.example."
+ret=0
+keyname=`./keycreate $dhkeyname bar.example.` || ret=1
+if [ $ret != 0 ]; then
+        echo "I:failed"
+        echo "I:exit status: $status"
+        exit $status
+fi
+status=`expr $status + $ret`
+
+echo "I:checking the key with 'rndc tsig-list'"
+ret=0
+$RNDC -c ../common/rndc.conf -s 10.53.0.1 -p 9953 tsig-list > rndc.out
+grep "key \"bar.example.server" rndc.out > /dev/null || ret=1
+if [ $ret != 0 ]; then
+        echo "I:failed"
+fi
+status=`expr $status + $ret`
+
+echo "I:deleting the key with 'rndc tsig-delete'"
+ret=0
+$RNDC -c ../common/rndc.conf -s 10.53.0.1 -p 9953 tsig-delete bar.example.server > /dev/null || ret=1
+$RNDC -c ../common/rndc.conf -s 10.53.0.1 -p 9953 tsig-list > rndc.out
+grep "key \"bar.example.server" rndc.out > /dev/null && ret=1
+if [ $ret != 0 ]; then
+        echo "I:failed"
+fi
+status=`expr $status + $ret`
+
 echo "I:exit status: $status"
 exit $status
index 878cdbf1f5158442bf118c7be59985daeb22ec63..11871a470b0228fb8de20e3ad2715736954067d4 100644 (file)
@@ -18,7 +18,7 @@
  - PERFORMANCE OF THIS SOFTWARE.
 -->
 
-<!-- File: $Id: Bv9ARM-book.xml,v 1.511 2011/11/03 04:53:27 each Exp $ -->
+<!-- File: $Id: Bv9ARM-book.xml,v 1.512 2011/11/03 22:06:21 each Exp $ -->
 <book xmlns:xi="http://www.w3.org/2001/XInclude">
   <title>BIND 9 Administrator Reference Manual</title>
 
@@ -1496,6 +1496,31 @@ zone "eng.example.com" {
                     </listitem>
                   </varlistentry>
 
+                  <varlistentry>
+                    <term><userinput>tsig-list</userinput></term>
+                    <listitem>
+                      <para>
+                        List the names of all TSIG keys currently configured
+                        for use by <command>named</command> in each view.  The
+                        list both statically configured keys and dynamic
+                        TKEY-negotiated keys.
+                      </para>
+                    </listitem>
+                  </varlistentry>
+
+                  <varlistentry>
+                    <term><userinput>tsig-delete</userinput>
+                     <replaceable>keyname</replaceable>
+                     <optional><replaceable>view</replaceable></optional></term>
+                    <listitem>
+                      <para>
+                        Delete a given TKEY-negotated key from the server.
+                        (This does not apply to statically configured TSIG
+                        keys.)
+                      </para>
+                    </listitem>
+                  </varlistentry>
+
                   <varlistentry>
                     <term><userinput>addzone
                         <replaceable>zone</replaceable>