9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt/*
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * Copyright (C) 2011 Internet Systems Consortium, Inc. ("ISC")
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt *
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * Permission to use, copy, modify, and/or distribute this software for any
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * purpose with or without fee is hereby granted, provided that the above
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * copyright notice and this permission notice appear in all copies.
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt *
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * PERFORMANCE OF THIS SOFTWARE.
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt */
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt/*
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * This is a sample named.conf file that uses the DLZ module defined in
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * dlz_example.c. It sets up a zone 'example.nil' which can accept DDNS
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * updates.
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt *
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * By default, when run, the zone contains the following records:
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt *
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * example.nil. 3600 IN SOA example.nil. hostmaster.example.nil. (
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * 123 900 600 86400 3600
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * )
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * example.nil. 3600 IN NS example.nil.
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * example.nil. 1800 IN A 10.53.0.1
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt *
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * Additionally, a query for 'source-addr.example.nil/TXT' is always
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * answered with the source address of the query. This is used to
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * demonstrate the code that retreives client information from the
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * caller.
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt *
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * To use this driver, "dlz_external.so" must be moved into the working
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt * directory for named.
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt */
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt
9336f01769f16a8eda79340094d663db0f8537c7Evan Huntoptions {
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt allow-transfer { any; };
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt allow-query { any; };
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt notify yes;
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt recursion no;
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt};
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt/*
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * To test dynamic updates, create a DDNS key:
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt *
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * ddns-confgen -q -z example.nil > ddns.key
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt *
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * Then uncomment the following line:
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt *
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * include "ddns.key";
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt *
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * Use "nsupdate -k ddns.key" when sending updates. (NOTE: This driver does
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * not check the key that's used: as long as the update is signed by a key
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * known to named, the update will be accepted. Only updates to names
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt * that begin with "deny." are rejected.)
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt */
aefb3e308ba01ad47a3d3aaadf77a5edd4261cb9Evan Hunt
9336f01769f16a8eda79340094d663db0f8537c7Evan Huntdlz "example" {
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt database "dlopen ./dlz_example.so example.nil";
9336f01769f16a8eda79340094d663db0f8537c7Evan Hunt};