/usr/lib/python3.9/site-packages/dns/__pycache__
NameSizeModeActions
asyncbackend.cpython-39.opt-1.pyc26160644editdlrm
asyncbackend.cpython-39.pyc26160644editdlrm
asyncquery.cpython-39.opt-1.pyc178050644editdlrm
asyncquery.cpython-39.pyc178170644editdlrm
asyncresolver.cpython-39.opt-1.pyc129580644editdlrm
asyncresolver.cpython-39.pyc130020644editdlrm
dnssec.cpython-39.opt-1.pyc321600644editdlrm
dnssec.cpython-39.pyc321880644editdlrm
dnssectypes.cpython-39.opt-1.pyc16160644editdlrm
dnssectypes.cpython-39.pyc16160644editdlrm
e164.cpython-39.opt-1.pyc34520644editdlrm
e164.cpython-39.pyc34520644editdlrm
edns.cpython-39.opt-1.pyc147200644editdlrm
edns.cpython-39.pyc147340644editdlrm
entropy.cpython-39.opt-1.pyc33480644editdlrm
entropy.cpython-39.pyc33480644editdlrm
enum.cpython-39.opt-1.pyc32490644editdlrm
enum.cpython-39.pyc32490644editdlrm
exception.cpython-39.opt-1.pyc55180644editdlrm
exception.cpython-39.pyc57140644editdlrm
flags.cpython-39.opt-1.pyc22080644editdlrm
flags.cpython-39.pyc22080644editdlrm
grange.cpython-39.opt-1.pyc10890644editdlrm
grange.cpython-39.pyc11330644editdlrm
immutable.cpython-39.opt-1.pyc24280644editdlrm
immutable.cpython-39.pyc24280644editdlrm
inet.cpython-39.opt-1.pyc46030644editdlrm
inet.cpython-39.pyc46030644editdlrm
ipv4.cpython-39.opt-1.pyc18440644editdlrm
ipv4.cpython-39.pyc18440644editdlrm
ipv6.cpython-39.opt-1.pyc39380644editdlrm
ipv6.cpython-39.pyc39380644editdlrm
message.cpython-39.opt-1.pyc506310644editdlrm
message.cpython-39.pyc506720644editdlrm
name.cpython-39.opt-1.pyc350740644editdlrm
name.cpython-39.pyc350890644editdlrm
namedict.cpython-39.opt-1.pyc29860644editdlrm
namedict.cpython-39.pyc29860644editdlrm
nameserver.cpython-39.opt-1.pyc89080644editdlrm
nameserver.cpython-39.pyc89080644editdlrm
node.cpython-39.opt-1.pyc116050644editdlrm
node.cpython-39.pyc116050644editdlrm
opcode.cpython-39.opt-1.pyc24750644editdlrm
opcode.cpython-39.pyc24750644editdlrm
query.cpython-39.opt-1.pyc402980644editdlrm
query.cpython-39.pyc403430644editdlrm
rcode.cpython-39.opt-1.pyc32530644editdlrm
rcode.cpython-39.pyc32530644editdlrm
rdata.cpython-39.opt-1.pyc236090644editdlrm
rdata.cpython-39.pyc236090644editdlrm
rdataclass.cpython-39.opt-1.pyc27920644editdlrm
rdataclass.cpython-39.pyc27920644editdlrm
rdataset.cpython-39.opt-1.pyc154370644editdlrm
rdataset.cpython-39.pyc154510644editdlrm
rdatatype.cpython-39.opt-1.pyc66730644editdlrm
rdatatype.cpython-39.pyc66730644editdlrm
renderer.cpython-39.opt-1.pyc98220644editdlrm
renderer.cpython-39.pyc98410644editdlrm
resolver.cpython-39.opt-1.pyc524720644editdlrm
resolver.cpython-39.pyc526250644editdlrm
reversename.cpython-39.opt-1.pyc30550644editdlrm
reversename.cpython-39.pyc30550644editdlrm
rrset.cpython-39.opt-1.pyc78850644editdlrm
rrset.cpython-39.pyc78990644editdlrm
serial.cpython-39.opt-1.pyc29330644editdlrm
serial.cpython-39.pyc29330644editdlrm
set.cpython-39.opt-1.pyc87990644editdlrm
set.cpython-39.pyc87990644editdlrm
tokenizer.cpython-39.opt-1.pyc172420644editdlrm
tokenizer.cpython-39.pyc172560644editdlrm
transaction.cpython-39.opt-1.pyc202610644editdlrm
transaction.cpython-39.pyc202610644editdlrm
tsig.cpython-39.opt-1.pyc103810644editdlrm
tsig.cpython-39.pyc103810644editdlrm
tsigkeyring.cpython-39.opt-1.pyc18350644editdlrm
tsigkeyring.cpython-39.pyc18350644editdlrm
ttl.cpython-39.opt-1.pyc16800644editdlrm
ttl.cpython-39.pyc16800644editdlrm
update.cpython-39.opt-1.pyc88860644editdlrm
update.cpython-39.pyc88860644editdlrm
version.cpython-39.opt-1.pyc5630644editdlrm
version.cpython-39.pyc5630644editdlrm
versioned.cpython-39.opt-1.pyc87230644editdlrm
versioned.cpython-39.pyc87750644editdlrm
win32util.cpython-39.opt-1.pyc56530644editdlrm
win32util.cpython-39.pyc56530644editdlrm
wire.cpython-39.opt-1.pyc33270644editdlrm
wire.cpython-39.pyc33550644editdlrm
xfr.cpython-39.opt-1.pyc77710644editdlrm
xfr.cpython-39.pyc77890644editdlrm
zone.cpython-39.opt-1.pyc452680644editdlrm
zone.cpython-39.pyc454120644editdlrm
zonefile.cpython-39.opt-1.pyc176630644editdlrm
zonefile.cpython-39.pyc176870644editdlrm
zonetypes.cpython-39.opt-1.pyc10230644editdlrm
zonetypes.cpython-39.pyc10230644editdlrm
_asyncbackend.cpython-39.opt-1.pyc42080644editdlrm
_asyncbackend.cpython-39.pyc42080644editdlrm
_asyncio_backend.cpython-39.opt-1.pyc89840644editdlrm
_asyncio_backend.cpython-39.pyc90020644editdlrm
_ddr.cpython-39.opt-1.pyc40710644editdlrm
_ddr.cpython-39.pyc40710644editdlrm
_features.cpython-39.opt-1.pyc23670644editdlrm
_features.cpython-39.pyc23670644editdlrm
_immutable_ctx.cpython-39.opt-1.pyc21590644editdlrm
_immutable_ctx.cpython-39.pyc21590644editdlrm
__init__.cpython-39.opt-1.pyc6670644editdlrm
__init__.cpython-39.pyc6670644editdlrm
Edit: /usr/lib/python3.9/site-packages/dns/__pycache__/rdataset.cpython-39.pyc (15451B)
a MetA @sdZddlZddlZddlZddlmZmZmZmZm Z m Z m Z ddl Z ddlZ ddlZ ddlZ ddlZ ddlZ ddlZ ddlZ ddlZ e jjZGddde jjZGddde jjZGdd d e jjZe jjGd d d eZde e j j!e"fe e j#j$e"fe%ee"e e j&j'e e j&j(e)e e j&j(ed ddZ*e e j j!e"fe e j#j$e"fe%eedddZ+e%ee j,j-edddZ.e%eedddZ/dS)zHDNS rdatasets (an rdataset is a set of rdatas of a given type and class)N)Any CollectionDictListOptionalUnioncastc@seZdZdZdS)DifferingCoversz~An attempt was made to add a DNS SIG/RRSIG whose covered type is not the same as that of the other rdatas in the rdataset.N__name__ __module__ __qualname____doc__rr0/usr/lib/python3.9/site-packages/dns/rdataset.pyr 'sr c@seZdZdZdS)IncompatibleTypesz?An attempt was made to add DNS RR data of an incompatible type.Nr rrrrr,src seZdZdZgdZejjdfejj ejj ejj e dfdd Z fddZ e dd d d Zd-ejjee dd fd d ZfddZfddZfddZddZddZddZfddZddZd.eejjeejjeeejj eeee fed!d"d#Z!d/ejje eejj"eejjeejj ee d$d%d&Z#ejj ejj ejj ed'd(d)Z$e%ejjd*d+d,Z&Z'S)0RdatasetzA DNS rdataset.)rdclassrdtypecoversttlrcs&t||_||_||_||_dS)a5Create a new rdataset of the specified class and type. *rdclass*, a ``dns.rdataclass.RdataClass``, the rdataclass. *rdtype*, an ``dns.rdatatype.RdataType``, the rdatatype. *covers*, an ``dns.rdatatype.RdataType``, the covered rdatatype. *ttl*, an ``int``, the TTL. N)super__init__rrrr)selfrrrr __class__rrr5s  zRdataset.__init__cs.t}|j|_|j|_|j|_|j|_|SN)r_clonerrrr)robjrrrrMs  zRdataset._cloneN)rreturncCs4tj|}t|dkr ||_n||jkr0||_dS)aPerform TTL minimization. Set the TTL of the rdataset to be the lesser of the set's current TTL or the specified TTL. If the set contains no rdatas, set the TTL to the specified TTL. *ttl*, an ``int`` or ``str``. rN)dnsrmakelenrrrrr update_ttlUs   zRdataset.update_ttl)rdrrcs|j|jks|j|jkrt|dur.|||jtjjksJ|jtjjkr|}t |dkrt|jtjj krt||_n|j|krt tj |jrt |dkr| t|dS)a!Add the specified rdata to the rdataset. If the optional *ttl* parameter is supplied, then ``self.update_ttl(ttl)`` will be called prior to adding the rdata. *rd*, a ``dns.rdata.Rdata``, the rdata *ttl*, an ``int``, the TTL. Raises ``dns.rdataset.IncompatibleTypes`` if the type and class do not match the type and class of the rdataset. Raises ``dns.rdataset.DifferingCovers`` if the type is a signature type and the covered type does not match that of the rdataset. Nr)rrrr$r rdatatypeZRRSIGZSIGrr"NONEr Z is_singletonclearradd)rr%rrrrrr)ds  z Rdataset.addcs||jt|dSr)r$rr union_updaterotherrrrr*s zRdataset.union_updatecs||jt|dSr)r$rrintersection_updater+rrrr-s zRdataset.intersection_updatecs||jt|dS)zAdd all rdatas in other to self. *other*, a ``dns.rdataset.Rdataset``, the rdataset from which to update. N)r$rrupdater+rrrr.s zRdataset.updatecs$ddddfdd|DS)NcSs t|dkr|dddS|S)Ndz...)r")srrrmaybe_truncates z,Rdataset._rdata_repr..maybe_truncatez[%s]z, c3s|]}dt|VqdS)z<%s>N)str).0Zrrr1rr z'Rdataset._rdata_repr..)joinrrr4r _rdata_reprszRdataset._rdata_reprcCs^|jdkrd}ndtj|jd}dtj|jdtj|j|d|dS) Nr()z)rr r&to_text rdataclassrrr9)rZctextrrr__repr__s&   zRdataset.__repr__cCs|Sr)r?r8rrr__str__szRdataset.__str__csBt|tsdS|j|jks2|j|jks2|j|jkr6dSt|S)NF) isinstancerrrrr__eq__r+rrrrDs    zRdataset.__eq__cCs || Sr)rDr+rrr__ne__szRdataset.__ne__TF)nameorigin relativizeoverride_rdclass want_commentskwrc Ks|dur"|||}t|}d}nd}d}t} |dur@|} n|j} t|dkr|| d||tj | tj |j nf|D]`} d} |r| j rd| j } | d|||jtj | tj |j | j f||d|| fq| dd S) auConvert the rdataset into DNS zone file format. See ``dns.name.Name.choose_relativity`` for more information on how *origin* and *relativize* determine the way names are emitted. Any additional keyword arguments are passed on to the rdata ``to_text()`` method. *name*, a ``dns.name.Name``. If name is not ``None``, emit RRs with *name* as the owner name. *origin*, a ``dns.name.Name`` or ``None``, the origin for relative names. *relativize*, a ``bool``. If ``True``, names will be relativized to *origin*. *override_rdclass*, a ``dns.rdataclass.RdataClass`` or ``None``. If not ``None``, use this class instead of the Rdataset's class. *want_comments*, a ``bool``. If ``True``, emit comments for rdata which have them. The default is ``False``. Nr=r:rz {}{}{} {} z ;z%s%s%d %s %s %s%s )rGrH)Zchoose_relativityr2ioStringIOrr"writeformatr r@r?r&rZ rdcommentrgetvalue) rrFrGrHrIrJrKZntextZpadr0rr%Zextrarrrr?sJ"        zRdataset.to_text)rFfilecompressrGrI want_shufflerc Cs|dur|}d}n|j}t|dkrP|||||td|j|dddS|rht|}t |n|}|D]h} |||||td|j||j t j |d| |||Wdqp1s0Yqpt|SdS)atConvert the rdataset to wire format. *name*, a ``dns.name.Name`` is the owner name to use. *file* is the file where the name is emitted (typically a BytesIO file). *compress*, a ``dict``, is the compression table to use. If ``None`` (the default), names will not be compressed. *origin* is a ``dns.name.Name`` or ``None``. If the name is relative and origin is not ``None``, then *origin* will be appended to it. *override_rdclass*, an ``int``, is used as the class instead of the class of the rdataset. This is useful when rendering rdatasets associated with dynamic updates. *want_shuffle*, a ``bool``. If ``True``, then the order of the Rdatas within the Rdataset will be shuffled before rendering. Returns an ``int``, the number of records emitted. NFrz!HHIHz!HHI)rr"to_wirerOstructpackrlistrandomZshufflerr ZrendererZprefixed_length) rrFrRrSrGrIrTrlr%rrrrWs$!  .zRdataset.to_wire)rrrrcCs&|j|kr"|j|kr"|j|kr"dSdS)zaReturns ``True`` if this rdataset matches the specified class, type, and covers. TF)rrr)rrrrrrrmatchQs zRdataset.match)rcCs&t|dkrgS|dt|SdS)aTReturn rdatas in a valid processing order according to the type's specification. For example, MX records are in preference order from lowest to highest preferences, with items of the same preference shuffled. For types that do not define a processing order, the rdatas are simply shuffled. rN)r"Z_processing_orderiterr8rrrprocessing_order^s zRdataset.processing_order)N)NNTNF)NNNT)(r r r r __slots__r r&r'r@ RdataClass RdataTypeintrrr$rdataRdatarr)r*r-r.r9rArBrDrErFNameboolrr2rr?Z CompressTyperWr]rr_ __classcell__rrrrr0st  '         W    : rcseZdZdZeZedfdd ZddZd(dd Zd d Z d d Z ddZ ddZ ddZ ddZddZddZddZfddZfddZfd d!Zfd"d#Zfd$d%Zfd&d'ZZS))ImmutableRdatasetzAn immutable DNS rdataset.)rdatasetcs.t|j|j|j|jtj|j |_ dS)z9Create an immutable rdataset from the specified rdataset.N) rrrrrrr immutableritems)rrjrrrrsszImmutableRdataset.__init__cCs tddSNrk TypeErrorr#rrrr${szImmutableRdataset.update_ttlNcCs tddSrmrn)rr%rrrrr)~szImmutableRdataset.addcCs tddSrmrnr+rrrr*szImmutableRdataset.union_updatecCs tddSrmrnr+rrrr-sz%ImmutableRdataset.intersection_updatecCs tddSrmrnr+rrrr.szImmutableRdataset.updatecCs tddSrmrn)rirrr __delitem__szImmutableRdataset.__delitem__cCs tddSrmrnr+rrr__ior__szImmutableRdataset.__ior__cCs tddSrmrnr+rrr__iand__szImmutableRdataset.__iand__cCs tddSrmrnr+rrr__iadd__szImmutableRdataset.__iadd__cCs tddSrmrnr+rrr__isub__szImmutableRdataset.__isub__cCs tddSrmrnr8rrrr(szImmutableRdataset.clearcsttSrrircopyr8rrr__copy__szImmutableRdataset.__copy__csttSrrvr8rrrrwszImmutableRdataset.copycstt|Sr)rirunionr+rrrryszImmutableRdataset.unioncstt|Sr)rir intersectionr+rrrrzszImmutableRdataset.intersectioncstt|Sr)rir differencer+rrrr{szImmutableRdataset.differencecstt|Sr)rirsymmetric_differencer+rrrr|sz&ImmutableRdataset.symmetric_difference)N)r r r rrZ _clone_classrr$r)r*r-r.rqrrrsrtrur(rxrwryrzr{r|rhrrrrrims(      riT) rrr text_rdatas idna_codecrGrH relativize_torc Csdtjj|}tjj|}t||}|||D]*} tj |j |j | ||||} | | q4|S)a|Create an rdataset with the specified class, type, and TTL, and with the specified list of rdatas in text format. *idna_codec*, a ``dns.name.IDNACodec``, specifies the IDNA encoder/decoder to use; if ``None``, the default IDNA 2003 encoder/decoder is used. *origin*, a ``dns.name.Name`` (or ``None``), the origin to use for relative names. *relativize*, a ``bool``. If true, name will be relativized. *relativize_to*, a ``dns.name.Name`` (or ``None``), the origin to use when relativizing names. If not set, the *origin* value will be used. Returns a ``dns.rdataset.Rdataset`` object. ) r r@rar!r&rbrr$rd from_textrrr)) rrrr}r~rGrHrrtr%rrrfrom_text_lists   r)rrrr}rcGst|||ttt|S)zCreate an rdataset with the specified class, type, and TTL, and with the specified rdatas in text format. Returns a ``dns.rdataset.Rdataset`` object. )rrrr2)rrrr}rrrrs r)rrdatasrcCs\t|dkrtdd}|D].}|dur@t|j|j}||||q|dusXJ|S)zCreate an rdataset with the specified TTL, and with the specified list of rdata objects. Returns a ``dns.rdataset.Rdataset`` object. rzrdata list must not be emptyN)r" ValueErrorrrrr$r))rrrr%rrrfrom_rdata_lists    rcGst|tttjj|S)zCreate an rdataset with the specified TTL, and with the specified rdata objects. Returns a ``dns.rdataset.Rdataset`` object. )rrrr rdre)rrrrr from_rdatasr)NNTN)0rrMr[rXtypingrrrrrrrZ dns.exceptionr Z dns.immutableZdns.nameZ dns.rdataZdns.rdataclassZ dns.rdatatypeZ dns.rendererZdns.setZdns.ttlsetSetZ SimpleSet exceptionZ DNSExceptionr rrrkrir@rar2r&rbrcrFZ IDNACodecrfrgrrrdrerrrrrrsX$?J    )