"Fossies" - the Fresh Open Source Software Archive

Member "bind-9.16.7/lib/irs/include/irs/dnsconf.h" (4 Sep 2020, 2480 Bytes) of package /linux/misc/dns/bind9/9.16.7/bind-9.16.7.tar.xz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "dnsconf.h" see the Fossies "Dox" file reference documentation.

    1 /*
    2  * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
    3  *
    4  * This Source Code Form is subject to the terms of the Mozilla Public
    5  * License, v. 2.0. If a copy of the MPL was not distributed with this
    6  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
    7  *
    8  * See the COPYRIGHT file distributed with this work for additional
    9  * information regarding copyright ownership.
   10  */
   11 
   12 #ifndef IRS_DNSCONF_H
   13 #define IRS_DNSCONF_H 1
   14 
   15 /*! \file
   16  *
   17  * \brief
   18  * The IRS dnsconf module parses an "advanced" configuration file related to
   19  * the DNS library, such as trust anchors for DNSSEC validation, and creates
   20  * the corresponding configuration objects for the DNS library modules.
   21  *
   22  * Notes:
   23  * This module is very experimental and the configuration syntax or library
   24  * interfaces may change in future versions.  Currently, only static
   25  * key configuration is supported; "trusted-keys" and "trust-anchors"/
   26  * "managed-keys" statements will be parsed exactly as they are in
   27  * named.conf, except that "trust-anchors" and "managed-keys" entries will
   28  * be treated as if they were configured with "static-key", even if they
   29  * were actually configured with "initial-key".
   30  */
   31 
   32 #include <irs/types.h>
   33 
   34 /*%
   35  * A compound structure storing DNS key information mainly for DNSSEC
   36  * validation.  A dns_key_t object will be created using the 'keyname' and
   37  * 'keydatabuf' members with the dst_key_fromdns() function.
   38  */
   39 typedef struct irs_dnsconf_dnskey {
   40     dns_name_t *  keyname;
   41     isc_buffer_t *keydatabuf;
   42     ISC_LINK(struct irs_dnsconf_dnskey) link;
   43 } irs_dnsconf_dnskey_t;
   44 
   45 typedef ISC_LIST(irs_dnsconf_dnskey_t) irs_dnsconf_dnskeylist_t;
   46 
   47 ISC_LANG_BEGINDECLS
   48 
   49 isc_result_t
   50 irs_dnsconf_load(isc_mem_t *mctx, const char *filename, irs_dnsconf_t **confp);
   51 /*%<
   52  * Load the "advanced" DNS configuration file 'filename' in the "dns.conf"
   53  * format, and create a new irs_dnsconf_t object from the configuration.
   54  *
   55  * Requires:
   56  *
   57  *\li   'mctx' is a valid memory context.
   58  *
   59  *\li   'filename' != NULL
   60  *
   61  *\li   'confp' != NULL && '*confp' == NULL
   62  */
   63 
   64 void
   65 irs_dnsconf_destroy(irs_dnsconf_t **confp);
   66 /*%<
   67  * Destroy the dnsconf object.
   68  *
   69  * Requires:
   70  *
   71  *\li   '*confp' is a valid dnsconf object.
   72  *
   73  * Ensures:
   74  *
   75  *\li   *confp == NULL
   76  */
   77 
   78 irs_dnsconf_dnskeylist_t *
   79 irs_dnsconf_gettrustedkeys(irs_dnsconf_t *conf);
   80 /*%<
   81  * Return a list of key information stored in 'conf'.
   82  *
   83  * Requires:
   84  *
   85  *\li   'conf' is a valid dnsconf object.
   86  */
   87 
   88 ISC_LANG_ENDDECLS
   89 
   90 #endif /* IRS_DNSCONF_H */