Home | Trees | Indices | Help |
|
---|
|
object --+ | Resolver
DNS stub resolver.
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from |
|
|||
Inherited from |
|
*filename*, a ``text`` or file object, specifying a file in standard /etc/resolv.conf format. This parameter is meaningful only when *configure* is true and the platform is POSIX. *configure*, a ``bool``. If True (the default), the resolver instance is configured in the normal fashion for the operating system the resolver is running on. (I.e. by reading a /etc/resolv.conf file on POSIX systems and from the registry on Windows systems.)
|
Process *f* as a file in the /etc/resolv.conf format. If f is a ``text``, it is used as the name of the file to open; otherwise it is treated as the file itself. |
Query nameservers to find the answer to the question. The *qname*, *rdtype*, and *rdclass* parameters may be objects of the appropriate type, or strings that can be converted into objects of the appropriate type. *qname*, a ``dns.name.Name`` or ``text``, the query name. *rdtype*, an ``int`` or ``text``, the query type. *rdclass*, an ``int`` or ``text``, the query class. *tcp*, a ``bool``. If ``True``, use TCP to make the query. *source*, a ``text`` or ``None``. If not ``None``, bind to this IP address when making queries. *raise_on_no_answer*, a ``bool``. If ``True``, raise ``dns.resolver.NoAnswer`` if there's no answer to the question. *source_port*, an ``int``, the port from which to send the message. *lifetime*, a ``float``, how long query should run before timing out. Raises ``dns.exception.Timeout`` if no answers could be found in the specified lifetime. Raises ``dns.resolver.NXDOMAIN`` if the query name does not exist. Raises ``dns.resolver.YXDOMAIN`` if the query name is too long after DNAME substitution. Raises ``dns.resolver.NoAnswer`` if *raise_on_no_answer* is ``True`` and the query name exists but has no RRset of the desired type and class. Raises ``dns.resolver.NoNameservers`` if no non-broken nameservers are available to answer the question. Returns a ``dns.resolver.Answer`` instance. |
Add a TSIG signature to the query. See the documentation of the Message class for a complete description of the keyring dictionary. *keyring*, a ``dict``, the TSIG keyring to use. If a *keyring* is specified but a *keyname* is not, then the key used will be the first key in the *keyring*. Note that the order of keys in a dictionary is not defined, so applications should supply a keyname when a keyring is used, unless they know the keyring contains only one key. *keyname*, a ``dns.name.Name`` or ``None``, the name of the TSIG key to use; defaults to ``None``. The key must be defined in the keyring. *algorithm*, a ``dns.name.Name``, the TSIG algorithm to use. |
Configure EDNS behavior. *edns*, an ``int``, is the EDNS level to use. Specifying ``None``, ``False``, or ``-1`` means "do not use EDNS", and in this case the other parameters are ignored. Specifying ``True`` is equivalent to specifying 0, i.e. "use EDNS0". *ednsflags*, an ``int``, the EDNS flag values. *payload*, an ``int``, is the EDNS sender's payload field, which is the maximum size of UDP datagram the sender can handle. I.e. how big a response to this message can be. |
Overrides the default flags with your own. *flags*, an ``int``, the message flags to use. |
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sat Dec 8 10:59:55 2018 | http://epydoc.sourceforge.net |