File: //usr/lib/python3/dist-packages/twisted/names/__pycache__/client.cpython-310.pyc
o
�b�_ � @ s d Z ddlZddlZddlZddlmZ ddlmZmZm Z m
Z
ddlmZ ddl
mZmZmZmZmZmZ ddlmZmZ ddlmZ dd lmZ dd
lmZ ee j� G dd� dej�Z G d
d� d�Z!ddl"m#Z$ G dd� de$�Z#G dd� de
j%�Z&dKdd�Z'da(dd� Z)dLdd�Z*dMdd�Z+dMdd�Z,dMdd �Z-dMd!d"�Z.dMd#d$�Z/dMd%d&�Z0dMd'd(�Z1dMd)d*�Z2dMd+d,�Z3dMd-d.�Z4dMd/d0�Z5dMd1d2�Z6dMd3d4�Z7dMd5d6�Z8dMd7d8�Z9dMd9d:�Z:dMd;d<�Z;dMd=d>�Z<dMd?d@�Z=dMdAdB�Z>dMdCdD�Z?dMdEdF�Z@dMdGdH�ZAdMdIdJ�ZBdS )Na�
Asynchronous client DNS
The functions exposed in this module can be used for asynchronous name
resolution and dns queries.
If you need to create a resolver with specific requirements, such as needing to
do queries against a particular host, the L{createResolver} function will
return an C{IResolver}.
Future plans: Proper nameserver acquisition on Windows/MacOS,
better caching, respect timeouts
� N)�moduleProvides)�defer�error�
interfaces�protocol)�
isIPv6Address)�cache�common�dns�hosts�resolve�root)�failure�log)�nativeString)�FilePath)�platformc @ s� e Zd ZdZdZdZdZdZdZdZ dZ
dZdZdZ
d1dd�Zd d
� Zdd� Zd
d� Zdd� Zdd� Zdd� Zd2dd�Zdd� Zdd� Zd3dd�Zdd� Zd3d d!�Zd"d#� Zd4d%d&�Zd'd(� Zd)d*� Zd4d+d,�Zd-d.� Z d/d0� Z!dS )5�Resolvera�
@ivar _waiting: A C{dict} mapping tuple keys of query name/type/class to
Deferreds which will be called back with the result of those queries.
This is used to avoid issuing the same query more than once in
parallel. This is more efficient on the network and helps avoid a
"birthday paradox" attack by keeping the number of outstanding requests
for a particular query fixed at one instead of allowing the attacker to
raise it to an arbitrary number.
@ivar _reactor: A provider of L{IReactorTCP}, L{IReactorUDP}, and
L{IReactorTime} which will be used to set up network resources and
track timeouts.
r N� �<