lwres_config.docbook revision 0c27b3fe77ac1d5094ba3521e8142d9e7973133f
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer<!--
70e5a7403f0e0a3bd292b8287c5fed5772c15270Automatic Updater - Copyright (C) 2000, 2001, 2004, 2005, 2007, 2014-2016 Internet Systems Consortium, Inc. ("ISC")
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews -
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer - This Source Code Form is subject to the terms of the Mozilla Public
ec5347e2c775f027573ce5648b910361aa926c01Automatic Updater - License, v. 2.0. If a copy of the MPL was not distributed with this
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer - file, You can obtain one at http://mozilla.org/MPL/2.0/.
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer-->
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews<!-- Converted by db4-upgrade version 1.0 -->
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews<refentry xmlns="http://docbook.org/ns/docbook" version="5.0">
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews <info>
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews <date>2007-06-18</date>
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews </info>
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews <refentryinfo>
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews <corpname>ISC</corpname>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <corpauthor>Internet Systems Consortium, Inc.</corpauthor>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer </refentryinfo>
07555e64d9102eae058efd58f872b4a3b9ddff61Mark Andrews
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <refmeta>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <refentrytitle>lwres_config</refentrytitle>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <manvolnum>3</manvolnum>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <refmiscinfo>BIND9</refmiscinfo>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer </refmeta>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <docinfo>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <copyright>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <year>2004</year>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <year>2005</year>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <year>2007</year>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <year>2014</year>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <year>2015</year>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <year>2016</year>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <holder>Internet Systems Consortium, Inc. ("ISC")</holder>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </copyright>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <copyright>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <year>2000</year>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <year>2001</year>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <holder>Internet Software Consortium.</holder>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </copyright>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </docinfo>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refnamediv>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refname>lwres_conf_init</refname>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refname>lwres_conf_clear</refname>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refname>lwres_conf_parse</refname>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refname>lwres_conf_print</refname>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refname>lwres_conf_get</refname>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews <refpurpose>lightweight resolver configuration</refpurpose>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews </refnamediv>
667c498942c0e605c1aab98bca6b90aac4cbbd71Mark Andrews
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <refsynopsisdiv>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <funcsynopsis>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer<funcsynopsisinfo>#include &lt;lwres/lwres.h&gt;</funcsynopsisinfo>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer<funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencevoid
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<function>lwres_conf_init</function></funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencevoid
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<function>lwres_conf_clear</function></funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencelwres_result_t
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<function>lwres_conf_parse</function></funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>const char *<parameter>filename</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencelwres_result_t
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<function>lwres_conf_print</function></funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>FILE *<parameter>fp</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencelwres_conf_t *
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence<function>lwres_conf_get</function></funcdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </funcprototype>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence</funcsynopsis>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </refsynopsisdiv>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <refsection><info><title>DESCRIPTION</title></info>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <para><function>lwres_conf_init()</function>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence creates an empty
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <type>lwres_conf_t</type>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence structure for lightweight resolver context
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <parameter>ctx</parameter>.
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </para>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <para><function>lwres_conf_clear()</function>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence frees up all the internal memory used by
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence that
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <type>lwres_conf_t</type>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence structure in resolver context
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <parameter>ctx</parameter>.
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence </para>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <para><function>lwres_conf_parse()</function>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence opens the file
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <parameter>filename</parameter>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence and parses it to initialise the resolver context
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <parameter>ctx</parameter>'s
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <type>lwres_conf_t</type>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence structure.
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer </para>
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <para><function>lwres_conf_print()</function>
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews prints the
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews <type>lwres_conf_t</type>
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews structure for resolver context
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews <parameter>ctx</parameter>
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews to the
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews <type>FILE</type>
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews <parameter>fp</parameter>.
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews </para>
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews </refsection>
07555e64d9102eae058efd58f872b4a3b9ddff61Mark Andrews <refsection><info><title>RETURN VALUES</title></info>
578f588228f5e04ccf648b6ae596f396ad6a22c9Mark Andrews
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <para><function>lwres_conf_parse()</function>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer returns <errorcode>LWRES_R_SUCCESS</errorcode>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer if it successfully read and parsed
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <parameter>filename</parameter>.
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer It returns <errorcode>LWRES_R_FAILURE</errorcode>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer if <parameter>filename</parameter>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer could not be opened or contained incorrect
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer resolver statements.
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </para>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <para><function>lwres_conf_print()</function>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer returns <errorcode>LWRES_R_SUCCESS</errorcode>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer unless an error occurred when converting the network addresses to a
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer numeric host address string.
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer If this happens, the function returns
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer <errorcode>LWRES_R_FAILURE</errorcode>.
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </para>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </refsection>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <refsection><info><title>SEE ALSO</title></info>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <para><citerefentry>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <refentrytitle>stdio</refentrytitle><manvolnum>3</manvolnum>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </citerefentry>,
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <citerefentry>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer <refentrytitle>resolver</refentrytitle><manvolnum>5</manvolnum>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </citerefentry>.
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </para>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </refsection>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <refsection><info><title>FILES</title></info>
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence <para><filename>/etc/resolv.conf</filename>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </para>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer </refsection>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer</refentry>
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer