2.0/Modules/m dns

From AnopeWiki
Revision as of 21:50, 12 May 2014 by Azander (Talk | contribs)

Jump to: navigation, search
Language

English

Section Extra_Modules
Module m_dns
Author Anope


Description

Adds support for the DNS protocol. By itself this module does nothing useful, but other modules such as m_dnsbl and os_dns require this.

name= 
The name of this module, referenced by other modules. Do not change.
nameserver= 
The nameserver to query. Use either the IP address of the name server or use the local machine's /etc/resolv.conf configuration file (on linux/unix) to use the system's default name server(s).
timeout= 
Timeout before the name server request fails. Do not set this too high or you will lag out services if you get a lot of DNS lookup queries.
ip= 
The IP address to listen on for queries. Leave it 0.0.0.0 unless you know what you are doing, or are using the os_DNS module.
port= 
The port to listen on. The default (aka standard) DNS port is 53. Do not change this unless you really know what you are doing.
'admin= 
This should be your DNS contact person.
nameservers= 
This is where your zone files reside and are served out to others.
refresh= 
Time, in seconds, that a server beyond your direct control can keep a local copy of your DNS looked up reconrd before having to re-request them from your name servers. Set this too low, your name servers will see a large increase in traffic, set it too high and changes can take a long time to be seen.
notify {...} 
What other name servers should be told, directly, or changes you have made.
ip= 
What IP address of the name server to notify.
port= 
What port should you do this notification on.


Default Configuration

/*
 * m_dns
 *
 * Adds support for the DNS protocol. By itself this module does nothing useful,
 * but other modules such as m_dnsbl and os_dns require this.
 */
#module
{
        name = "m_dns"
 
        /*
         * The nameserver to use for resolving hostnames, must be an IP or a resolver configuration file.
         * The below should work fine on all unix like systems. Windows users will have to find their nameservers
         * from ipconfig /all and put the IP here.
         */
        nameserver = "/etc/resolv.conf"
        #nameserver = "127.0.0.1"
 
        /*
         * How long to wait in seconds before a DNS query has timed out.
         */
        timeout = 5
 
 
        /* Only edit below if you are expecting to use os_dns or otherwise answer DNS queries. */
 
        /*
         * The IP and port services use to listen for DNS queries.
         * Note that ports less than 1024 are privileged on UNIX/Linux systems, and
         * require Anope to be started as root. If you do this, it is recommended you
         * set options:user and options:group so Anope can change users after binding
         * to this port.
         */
        ip = "0.0.0.0"
        port = 53
 
        /*
         * SOA record information.
         */
 
        /* E-mail address of the DNS administrator. */
        admin = "admin@example.com"
 
        /* This should be the names of the public facing nameservers serving the records. */
        nameservers = "ns1.example.com ns2.example.com"
 
        /* The time slave servers are allowed to cache. This should be reasonably low
         * if you want your records to be updated without much delay.
         */
        refresh = 3600
 
        /* A notify block. There should probably be one per nameserver listed in 'nameservers'.
         */
        notify
        {
                ip = "192.0.2.0"
                port = 53
        }
}