shell bypass 403

Cubjrnet7 Shell


name : rrset.cpython-39.opt-1.pyc
a

�M�e�#�@sNdZddlmZmZmZmZmZmZddlZ	ddl
Z	ddlZ	ddlZ	Gdd�de	j
j�Zdee	jjefeee	jjefee	jjefeeee	jjee	jjeee	jjed�
dd	�Zee	jjefeee	jjefee	jjefeed
�dd�Zdee	jjefeee	jjee	jjed
�dd�Zee	jjefeeed�dd�ZdS)z)DNS RRsets (an RRset is a named rdataset)�)�Any�
Collection�Dict�Optional�Union�castNcs<eZdZdZddgZejjdfejj	ej
jejjejje
ej
jd��fdd�
Z�fdd	�Zd
d�Zdd
�Z�fdd�Zeeed��fdd�Zd ejj	ej
jejjejje
ej
jed��fdd�
Zd!e
ejj	eeeefed��fdd�
Zd"ee
ejje
ejj	eeefed��fdd�
Zejjd�dd�Z�Z S)#�RRseta6A DNS RRset (named rdataset).

    RRset inherits from Rdataset, and RRsets can be treated as
    Rdatasets in most cases.  There are, however, a few notable
    exceptions.  RRsets have different to_wire() and to_text() method
    arguments, reflecting the fact that RRsets always have an owner
    name.
    �name�deletingN)r	�rdclass�rdtype�coversr
cs t��|||�||_||_dS)zCreate a new RRset.N)�super�__init__r	r
��selfr	rrr
r
��	__class__��-/usr/lib/python3.9/site-packages/dns/rrset.pyr(s
zRRset.__init__cst���}|j|_|j|_|S�N)r�_cloner	r
)r�objrrrr6s
zRRset._clonecCs�|jdkrd}ndtj�|j�d}|jdurDdtj�|j�}nd}dt|j�dtj�|j�dtj�|j	�||d|�
�d	S)
Nr��(�)z delete=z<DNS � z RRset: �>)r
�dns�	rdatatype�to_textr
�
rdataclass�strr	rrZ_rdata_repr)rZctextZdtextrrr�__repr__<s8

��������	�
��zRRset.__repr__cCs|��Sr)r �rrrr�__str__Ssz
RRset.__str__cs:t|t�r|j|jkr.dSnt|tjj�s.dSt��|�S)NF)�
isinstancerr	r�rdataset�Rdatasetr�__eq__)r�otherrrrr)Vs
zRRset.__eq__)�args�kwargs�returncs8t|dtjj�r"|j|i|��St�j|i|��SdS)a�Does this rrset match the specified attributes?

        Behaves as :py:func:`full_match()` if the first argument is a
        ``dns.name.Name``, and as :py:func:`dns.rdataset.Rdataset.match()`
        otherwise.

        (This behavior fixes a design mistake where the signature of this
        method became incompatible with that of its superclass.  The fix
        makes RRsets matchable as Rdatasets while preserving backwards
        compatibility.)
        rN)r&rr	�Name�
full_matchr�match)rr+r,rrrr0^szRRset.match)r	rrr
r
r-cs0t��|||�sdS|j|ks(|j|kr,dSdS)ztReturns ``True`` if this rrset matches the specified name, class,
        type, covers, and deletion state.
        FT)rr0r	r
rrrrr/os
zRRset.full_matchT)�origin�
relativize�kwr-cst�j|j|||jfi|��S)a�Convert the RRset 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.

        *origin*, a ``dns.name.Name`` or ``None``, the origin for relative
        names.

        *relativize*, a ``bool``.  If ``True``, names will be relativized
        to *origin*.
        )rr r	r
)rr1r2r3rrrr �s
��z
RRset.to_text)�file�compressr1r3r-cs t�j|j||||jfi|��S)z�Convert the RRset to wire format.

        All keyword arguments are passed to ``dns.rdataset.to_wire()``; see
        that function for details.

        Returns an ``int``, the number of records emitted.
        )r�to_wirer	r
)rr4r5r1r3rrrr6�s
��z
RRset.to_wire)r-cCstj�|jt|��S)zYConvert an RRset into an Rdataset.

        Returns a ``dns.rdataset.Rdataset``.
        )rr'�from_rdata_list�ttl�listr$rrr�to_rdataset�szRRset.to_rdataset)N)NT)NN)!�__name__�
__module__�__qualname__�__doc__�	__slots__rrZNONEr	r.r!�
RdataClass�	RdataTyperrrr#r%r)r�boolr0r/rr"r ZCompressType�intr6r'r(r:�
__classcell__rrrrrsV	�
��
��

��


�rT)
r	r8rr�text_rdatas�
idna_codecr1r2�
relativize_tor-c	
Cs�t|t�rtjj|d|d�}tjj�|�}tjj	�|�}t
|||�}	|	�|�|D]*}
tj�|	j
|	j|
||||�}|	�|�qR|	S)ayCreate an RRset with the specified name, TTL, class, and type, 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.rrset.RRset`` object.
    N�rF)r&r"rr	�	from_textr!r@ZmakerrAr�
update_ttl�rdatarr�add)r	r8rrrErFr1r2rG�r�t�rdrrr�from_text_list�s

�rP)r	r8rrrEr-cGst||||ttt|��S)z�Create an RRset with the specified name, TTL, class, and type and with
    the specified rdatas in text format.

    Returns a ``dns.rrset.RRset`` object.
    )rPrrr")r	r8rrrErrrrI�s
�rI)r	r8�rdatasrFr-cCsnt|t�rtjj|d|d�}t|�dkr0td��d}|D]0}|dur^t||j|j	�}|�
|�|�|�q8|S)a/Create an RRset with the specified name and TTL, and with
    the specified list of rdata objects.

    *idna_codec*, a ``dns.name.IDNACodec``, specifies the IDNA
    encoder/decoder to use; if ``None``, the default IDNA 2003
    encoder/decoder is used.

    Returns a ``dns.rrset.RRset`` object.

    NrHrzrdata list must not be empty)r&r"rr	rI�len�
ValueErrorrrrrJrL)r	r8rQrFrMrOrrrr7�s

r7)r	r8rQr-cGst||tttjj|��S)z�Create an RRset with the specified name and TTL, and with
    the specified rdata objects.

    Returns a ``dns.rrset.RRset`` object.
    )r7rrrrK�Rdata)r	r8rQrrr�
from_rdatasrU)NNTN)N) r>�typingrrrrrrZdns.namerZdns.rdataclassZdns.rdatasetZdns.rendererr'r(rr	r.r"rCr!r@rrAZ	IDNACodecrBrPrIrKrTr7rUrrrr�<module>sN $�


�,��

� 

© 2025 Cubjrnet7