148N/A - Copyright (C) 2000, 2001 Internet Software Consortium. 148N/A - Permission to use, copy, modify, and distribute this software for any 148N/A - purpose with or without fee is hereby granted, provided that the above 148N/A - copyright notice and this permission notice appear in all copies. 148N/A - THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM 148N/A - DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL 148N/A - IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL 148N/A - INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, 148N/A - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING 148N/A - FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, 148N/A - NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION 148N/A - WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 2899N/ACONTENT="Modular DocBook HTML Stylesheet Version 1.61 148N/A> -- rndc configuration file</
DIV 727N/A> is the configuration file
727N/A>, the BIND 9 name server control
727N/A utility. This file has a similar structure and syntax to
148N/A>. Statements are enclosed
148N/A in braces and terminated with a semi-colon. Clauses in
148N/A the statements are also semi-colon terminated. The usual
560N/A comment styles are supported:
148N/A> C++ style: // to end of line
> Unix style: # to end of line
statements: an options statement, a server statement
> statement contains three clauses.
> clause is followed by the
name or address of a name server. This host will be used when
no name server is given as an argument to
clause is followed by the name of a key which is identified by
> is provided on the rndc command line,
> clause is found in a matching
> statement, this default key will be
used to authenticate the server's commands and responses. The
> clause is followed by the port
to connect to on the remote name server. If no
> option is provided on the rndc command
> statement, this default port
> keyword, the server statement
includes a string which is the hostname or address for a name
server. The statement has two possible clauses:
match the name of a key statement in the file. The port number
specifies the port to connect to.
> statement begins with an identifying
string, the name of the key. The statement has two clauses.
> identifies the encryption algorithm
> to use; currently only HMAC-MD5 is
supported. This is followed by a secret clause which contains
the base-64 encoding of the algorithm's encryption key. The
base-64 string is enclosed in double quotes.
> There are two common ways to generate the base-64 string for the
secret. The BIND 9 program <
B be used to generate a random key, or the
>, can be used to generate a base-64
string from known input. <
B ship with BIND 9 but is available on many systems. See the
EXAMPLE section for sample command lines for each.
default-server localhost;
secret "c3Ryb25nIGVub3VnaCBmb3IgYSBtYW4gYnV0IG1hZGUgZm9yIGEgd29tYW4K";
> In the above example, <
B the server at localhost (127.0.0.1) and the key called samplekey.
Commands to the localhost server will use the samplekey key, which
must also be defined in the server's configuration file with the
same name and secret. The key statement indicates that samplekey
uses the HMAC-MD5 algorithm and its secret clause contains the
base-64 encoding of the HMAC-MD5 secret enclosed in double quotes.
> To generate a random secret with <
B>$ dnssec-keygen -a hmac-md5 -b 128 -n user rndc</
B> The base-64 string will appear in two files,
>Krndc.+157.+{random}.key</
TT>Krndc.+157.+{random}.private</
TT extracting the key to be placed in the
.key and .private files can be removed.
> To generate a random secret with <
B>$ echo "known plaintext for a secret" | mmencode</
B>NAME SERVER CONFIGURATION</
H2> The name server must be configured to accept rndc connections and
to recognize the key specified in the <
TT file, using the controls statement in <
TT See the sections on the <
TT BIND 9 Administrator Reference Manual for details.
>BIND 9 Administrator Reference Manual</
I> Internet Software Consortium