ok

Mini Shell

Direktori : /opt/imunify360/venv/lib/python3.11/site-packages/Crypto/PublicKey/__pycache__/
Upload File :
Current File : //opt/imunify360/venv/lib/python3.11/site-packages/Crypto/PublicKey/__pycache__/DSA.cpython-311.pyc

�

f��fjW���gd�ZddlZddlZddlZddlmZmZmZmZm	Z	ddl
mZddlm
Z
mZddlmZddlmZmZmZmZmZddlmZdd	lmZmZmZdd
lmZmZm Z Gd�de!��Z"d
�Z#dd�Z$dd�Z%d�Z&d�Z'd�Z(d�Z)d�Z*dd�Z+e+Z,dZ-dS))�generate�	construct�DsaKey�
import_key�N)�bchr�bord�tobytes�tostr�
iter_range)�Random)�PKCS8�PEM)�SHA256)�	DerObject�DerSequence�
DerInteger�DerObjectId�DerBitString)�Integer)�test_probable_prime�	COMPOSITE�PROBABLY_PRIME)�_expand_subject_public_key_info�_create_subject_public_key_info� _extract_subject_public_key_infoc��eZdZdZgd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Z		dd�ZeZeZd�Zd�Zd�Zd�Zd�Zd�Zd�ZdS)ra�Class defining an actual DSA key.
    Do not instantiate directly.
    Use :func:`generate`, :func:`construct` or :func:`import_key` instead.

    :ivar p: DSA modulus
    :vartype p: integer

    :ivar q: Order of the subgroup
    :vartype q: integer

    :ivar g: Generator
    :vartype g: integer

    :ivar y: Public key
    :vartype y: integer

    :ivar x: Private key
    :vartype x: integer

    :undocumented: exportKey, publickey
    ��y�g�p�q�xc	��t|�����}td��}|�|��s"tdt	||z
��z���||z
}|rB|td��kr/tdt	|td��z
��z���t|��|_dS)N�rrr r!z$Some DSA components are missing = %s�r"zUnknown DSA components = %s)�set�keys�issubset�
ValueError�str�dict�_key)�self�key_dict�	input_set�
public_set�	extra_sets     �v/builddir/build/BUILD/imunify360-venv-2.3.5/opt/imunify360/venv/lib64/python3.11/site-packages/Crypto/PublicKey/DSA.py�__init__zDsaKey.__init__gs�����
�
���(�(�	��.�/�/�
��"�"�9�-�-�	:��C� ��i�!7�8�8�9�:�:�
:��
�*�	��	;��c�&�k�k�1�1��:� ��S��[�[�!8�9�9�:�;�;�
;���N�N��	�	�	�c�������std���d|cxkr�jksntd����fd�dD��\}}}}t	jd|���}||z�|��}||z}	t|||��|z}
|||z|	|
zzz|z}tt|
|f��S)Nz)DSA public key cannot be used for signing�zk is not between 2 and q-1c�*��g|]}�j|��S��r,��.0�compr-s  �r2�
<listcomp>z DsaKey._sign.<locals>.<listcomp>y����G�G�G�$�d�i��o�G�G�Gr4)r"r!r r)�
min_inclusive�
max_exclusive)
�has_private�	TypeErrorr!r)r�random_range�inverse�pow�map�int)r-�m�kr"r!r r�blind_factor�inv_blind_k�blind_x�r�ss`           r2�_signzDsaKey._signss�������!�!�	I��G�H�H�H��A������������9�:�:�:�G�G�G�G�2F�G�G�G�
��1�a���+�!�9:�<�<�<��#�a�'�0�0��3�3���l�"����1�a�L�L�1���
�L�1�,�w��{�:�
;�q�@���3��A����r4c�8��|\}}�fd�dD��\}}}}d|cxkr|krnnd|cxkr|ksndSt|���|��}	|	|z|z}
|	|z|z}t||
|��t|||��z|z|z}||kS)Nc�*��g|]}�j|��Sr8r9r:s  �r2r=z"DsaKey._verify.<locals>.<listcomp>�r>r4)rr!r rrF)rrDrE)
r-rH�sigrMrNrr!r r�w�u1�u2�vs
`            r2�_verifyzDsaKey._verify�s�������1�G�G�G�G�2F�G�G�G�
��1�a���A�	�	�	�	��	�	�	�	�	�1�q�9�9�9�9�1�9�9�9�9��5��A�J�J���q�!�!���!�e�q�[���!�e�q�[��
��B��]�]�S��B��]�]�
*�Q�
.�!�3���A�v�
r4c��d|jvS)z!Whether this is a DSA private keyr"r9�r-s r2rAzDsaKey.has_private�s���d�i��r4c��dS)NFr8rYs r2�can_encryptzDsaKey.can_encrypt�s���ur4c��dS)NTr8rYs r2�can_signzDsaKey.can_sign�s���tr4c�X��t�fd�dD����}t|��S)z^A matching DSA public key.

        Returns:
            a new :class:`DsaKey` object
        c3�6�K�|]}|�j|fV��dS�Nr9)r;rIr-s  �r2�	<genexpr>z$DsaKey.public_key.<locals>.<genexpr>�s.����� Q� Q�q�!�T�Y�q�\�!2� Q� Q� Q� Q� Q� Qr4r$)r+r)r-�public_componentss` r2�
public_keyzDsaKey.public_key�s8���!� Q� Q� Q� Q�<P� Q� Q� Q�Q�Q���'�(�(�(r4c�
�t|�����t|�����krdSd}|jD]2}|o-t|j|d��t|j|d��k}�3|S)NFT)�boolrA�_keydata�getattrr,)r-�other�resultr<s    r2�__eq__z
DsaKey.__eq__�s����� � �"�"�#�#�t�E�,=�,=�,?�,?�'@�'@�@�@��5����M�	B�	B�D��B����D�$�!?�!?�!(���T�4�!@�!@�"A�F�F��
r4c�.�|�|��Sr`)rj)r-rhs  r2�__ne__z
DsaKey.__ne__�s���;�;�u�%�%�%�%r4c��ddlm}|�)Nr)�
PicklingError)�picklern)r-rns  r2�__getstate__zDsaKey.__getstate__�s��(�(�(�(�(�(��r4c� ���fd�dD��S)zPThe DSA domain parameters.

        Returns
            tuple : (p,q,g)
        c�D��g|]}t�j|����Sr8)rGr,r:s  �r2r=z!DsaKey.domain.<locals>.<listcomp>�s'���A�A�A���D�I�d�O�$�$�A�A�Ar4)r r!rr8rYs`r2�domainz
DsaKey.domain�s ���B�A�A�A��A�A�A�Ar4c��g}|jD]m}|dkr@t|j�����}|�d|fz���Ht||��r|�|���n|���r|�d��d|jjt|��d�
|��fzS)Nr zp(%d)�privatez
<%s @0x%x %s>�,)rfrr �size_in_bits�append�hasattrrA�	__class__�__name__�id�join)r-�attrsrI�bitss    r2�__repr__zDsaKey.__repr__�s�������	 �	 �A��C�x�x��t�v���3�3�5�5�����W��w�.�/�/�/�/���q�!�!�
 ����Q����������	$��L�L��#�#�#��$�.�"9�2�d�8�8�S�X�X�e�_�_�!U�U�Ur4c�r�	t|j|��S#t$rt|���wxYwr`)rGr,�KeyError�AttributeError)r-�items  r2�__getattr__zDsaKey.__getattr__�sD��	'��t�y���'�'�'���	'�	'�	'� ��&�&�&�	'���s��6rNc�����|�t|��}|�tj}|dkrc�fd�dD��}d���fd�|D��}dg|z}d�d	�|D����}	d
t	j|	��dd�zSt
�j�j�j	g��}
��
��r�|�d}|rS|sd
}t�j���
��}tj|t |||
|���}|rd}
nd}
d}n�|dkr|rt#d���d�j�j�j	�j�jg}t
|���
��}d}
n;|rt#d���t't t�j��|
��}d}
|dkr|S|dkr)t)j
||
dz||��}t|��St#d|z���)a�Export this DSA key.

        Args:
          format (string):
            The encoding for the output:

            - *'PEM'* (default). ASCII as per `RFC1421`_/ `RFC1423`_.
            - *'DER'*. Binary ASN.1 encoding.
            - *'OpenSSH'*. ASCII one-liner as per `RFC4253`_.
              Only suitable for public keys, not for private keys.

          passphrase (string):
            *Private keys only*. The pass phrase to protect the output.

          pkcs8 (boolean):
            *Private keys only*. If ``True`` (default), the key is encoded
            with `PKCS#8`_. If ``False``, it is encoded in the custom
            OpenSSL/OpenSSH container.

          protection (string):
            *Only in combination with a pass phrase*.
            The encryption scheme to use to protect the output.

            If :data:`pkcs8` takes value ``True``, this is the PKCS#8
            algorithm to use for deriving the secret and encrypting
            the private DSA key.
            For a complete list of algorithms, see :mod:`Crypto.IO.PKCS8`.
            The default is *PBKDF2WithHMAC-SHA1AndDES-EDE3-CBC*.

            If :data:`pkcs8` is ``False``, the obsolete PEM encryption scheme is
            used. It is based on MD5 for key derivation, and Triple DES for
            encryption. Parameter :data:`protection` is then ignored.

            The combination ``format='DER'`` and ``pkcs8=False`` is not allowed
            if a passphrase is present.

          randfunc (callable):
            A function that returns random bytes.
            By default it is :func:`Crypto.Random.get_random_bytes`.

        Returns:
          byte string : the encoded key

        Raises:
          ValueError : when the format is unknown or when you try to encrypt a private
            key with *DER* format and OpenSSL/OpenSSH.

        .. warning::
            If you don't provide a pass phrase, the private key will be
            exported in the clear!

        .. _RFC1421:    http://www.ietf.org/rfc/rfc1421.txt
        .. _RFC1423:    http://www.ietf.org/rfc/rfc1423.txt
        .. _RFC4253:    http://www.ietf.org/rfc/rfc4253.txt
        .. _`PKCS#8`:   http://www.ietf.org/rfc/rfc5208.txt
        N�OpenSSHc�N��g|]!}�j|�����"Sr8)r,�to_bytes)r;r"r-s  �r2r=z%DsaKey.export_key.<locals>.<listcomp>s+���J�J�J��D�I�a�L�)�)�+�+�J�J�Jr4)r r!rrc�Z�t|d��dzrtd��|zS|S)Nr�)rrr%s r2�funczDsaKey.export_key.<locals>.funcs.����1��J�J��%����7�7�Q�;�&��Hr4c�&��g|]
}�|����Sr8r8)r;r"r�s  �r2r=z%DsaKey.export_key.<locals>.<listcomp>s!���*�*�*��D�D��G�G�*�*�*r4�ssh-dssr4c�X�g|]'}tjdt|����|z��(S)�>I)�struct�pack�len)r;�kps  r2r=z%DsaKey.export_key.<locals>.<listcomp>s/��P�P�P��V�[��s�2�w�w�7�7�"�<�P�P�Pr4�ssh-dss ���Tz"PBKDF2WithHMAC-SHA1AndDES-EDE3-CBC)�
key_params�randfunczENCRYPTED PRIVATE�PRIVATErz#DSA private key cannot be encryptedrzDSA PRIVATEz*PKCS#8 is only meaningful for private keys�PUBLIC�DERz KEYz3Unknown key format '%s'. Cannot export the DSA key.)r	r�get_random_bytesr}�binascii�
b2a_base64rr r!rrArr"�encoder
�wrap�oidr)rrr)r-�format�pkcs8�
passphrase�
protectionr��tup1�tup2�keyparts�	keystring�params�private_key�
binary_key�key_type�ints�pem_strr�s`               @r2�
export_keyzDsaKey.export_key�sg����v�!� ��,�,�J����.�H��Y���J�J�J�J�5I�J�J�J�D�
�
�
�+�*�*�*�T�*�*�*�D�"�|�d�*�H����P�P�x�P�P�P���I���!4�Y�!?�!?����!D�D�D��d�f�d�f�d�f�5�6�6�������	 ��}����
)�!�F�!E�J�(���0�0�7�7�9�9��"�Z� +�S�*� *�v�)1�"�"�"�
�
�)�2�H�H�(�H�!�
�
��U�?�?�z�?�$�%J�K�K�K��4�6�4�6�4�6�4�6�4�6�B��(��.�.�5�5�7�7�
�(����
O� �!M�N�N�N�8�� *�4�6� 2� 2�F�<�<�J��H��U�?�?����U�?�?��j� *�H�v�,=� *�H���G��7�#�#�#��N�QW�W�X�X�Xr4c� �td����Nz'Use module Crypto.Signature.DSS instead��NotImplementedError)r-�M�Ks   r2�signzDsaKey.signU���!�"K�L�L�Lr4c� �td���r�r�)r-r��	signatures   r2�verifyz
DsaKey.verifyXr�r4c��t�r`r�)r-�	plaintextr�s   r2�encryptzDsaKey.encrypt[���!�!r4c��t�r`r�)r-�
ciphertexts  r2�decryptzDsaKey.decrypt^r�r4c��t�r`r��r-r��Bs   r2�blindzDsaKey.blindar�r4c��t�r`r�r�s   r2�unblindzDsaKey.unblinddr�r4c��t�r`r�rYs r2�sizezDsaKey.sizegr�r4)rNNNN)r{�
__module__�__qualname__�__doc__rfr3rOrWrAr[r]rcrjrlrprsr�r�r��	exportKey�	publickeyr�r�r�r�r�r�r�r8r4r2rrNs���������,)�(�(�H�
#�
#�
#� � � �"	�	�	� � � �
������)�)�)����&�&�&����
B�B�B�V�V�V�'�'�'�?C�,0�{Y�{Y�{Y�{Y�|�I��I�M�M�M�M�M�M�"�"�"�"�"�"�"�"�"�"�"�"�"�"�"�"�"r4rc�T�����dddd��|��}|�td|z���tjdz�|�zdz
�zdz
}|dz
|�zz
}t	d	��}d|dz
z}t||��tkrj|d
���t	jtj����	����|dz
z}||zdz}t||��tk�j|�
��|ksJ�d�d|dz
z}	��fd�t|dz��D���d
��D���t��fd�t|��D���|d|zdz
zd|�zzz��}t	||z��}	|	�
��|ksJ�|	|dzz}
|	|
dz
z
}|�
��|krt||��tkrn	�|dzz
���|dz
|z}tjd��D]�}
�dztd��zt	|
�����z}t	jtj|���	����}t#|||��}|dkrn��|||�fS)z+Generate a new set of DSA domain parameters����)���NzInvalid modulus length (%d)�r6��@Tc	���g|]M}tj�t�|z�����z�������NSr8)r�newrr��digest)r;�j�offset�seeds  ��r2r=z$_generate_domain.<locals>.<listcomp>�s\���
+�
+�
+���j�����
� 3� 3� <� <� >� >�>�?�?�F�F�H�H�
+�
+�
+r4c�6�g|]}tj|����Sr8�r�
from_bytes)r;rVs  r2r=z$_generate_domain.<locals>.<listcomp>�s#��0�0�0��g� ��#�#�0�0�0r4c�2��g|]}�|d|�zzz��S)r6r8)r;�i�V�outlens  ��r2r=z$_generate_domain.<locals>.<listcomp>�s+���C�C�C���1���q�6�z�*�+�C�C�Cr4�sggen)�getr)r�digest_sizerrrr�r�r�rwr�sum�	itertools�countrr�rE)�Lr��N�n�b_r!�	upper_bit�U�W�X�cr �er�rr�r�r�r�s               @@@@r2�_generate_domainr�ks	��������3�(�(�,�,�Q�/�/�A��y��6��:�;�;�;�
�
�!�
#�F�	
�V��a��F�"�Q�&�A�	
�Q��!�f�*�	�B�	��
�
�A��a�!�e��I�
�a��
*�
*�n�
<�
<��x��|�|����v�z�$�/�/�6�6�8�8�9�9�Y��]�K��
�	�M�A����a��
*�
*�n�
<�
<�

�>�>���q� � � � ��F��a�!�e��I��
+�
+�
+�
+�
+�!�!�a�%�(�(�
+�
+�
+��0�0�Q�0�0�0���C�C�C�C�C�Z��]�]�C�C�C��1��!�r�'�Q��'�A�!�f�*�,=�>�
@�
@��
�A�	�M�"�"���~�~���1�$�$�$�$�
��Q��K��
��Q��K���>�>���q� � ��q�(�+�+�~�=�=���!�a�%����$
�Q��1��A����#�#�����7�N�T�!�W�W�$�w�u�~�~�'>�'>�'@�'@�@����v�z�!�}�}�3�3�5�5�6�6����1�a�L�L����6�6��E��
�q�!�T�?�r4c��|�tj}|r�tt|��\}}}t	|��t
k}|t	|��t
kz}||dz
|zdkz}||dkp||kz}|t
|||��dkz}|rtd���nt||��\}}}}|�	��}|�	��}	||krtd||fz���||	fdvrtd||	fz���d|cxkr|ksntd���tj
|	d	z|�
��}
|
|dz
zdz}t
|||��}|||||d�}
t|
��S)a�Generate a new DSA key pair.

    The algorithm follows Appendix A.1/A.2 and B.1 of `FIPS 186-4`_,
    respectively for domain generation and key pair generation.

    Args:
      bits (integer):
        Key length, or size (in bits) of the DSA modulus *p*.
        It must be 1024, 2048 or 3072.

      randfunc (callable):
        Random number generation function; it accepts a single integer N
        and return a string of random data N bytes long.
        If not specified, :func:`Crypto.Random.get_random_bytes` is used.

      domain (tuple):
        The DSA domain parameters *p*, *q* and *g* as a list of 3
        integers. Size of *p* and *q* must comply to `FIPS 186-4`_.
        If not specified, the parameters are created anew.

    Returns:
      :class:`DsaKey` : a new DSA key object

    Raises:
      ValueError : when **bits** is too little, too big, or not a multiple of 64.

    .. _FIPS 186-4: http://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-4.pdf
    Nr6rzInvalid DSA domain parametersz?Mismatch between size of modulus (%d) and 'bits' parameter (%d)))r�r�)r�r�)r�r�)r�r�z;Lengths of p and q (%d, %d) are not compatibleto FIPS 186-3zIncorrent DSA generatorr�)�
exact_bitsr�r)rr�rFrrrrEr)r�rw�randomr)rr�rsr r!r�	fmt_error�_r�r�r�r"rr.s              r2rr�s���<���*��
�6��g�v�&�&���1�a�(��*�*�i�7�	��(��+�+�y�8�8�	��q�1�u��k�a�'�'�	��Q�!�V�%�q�A�v�%�	��S��A�q�\�\�Q�&�&�	��	>��<�=�=�=�	>�&�d�H�5�5�
��1�a��	�����A�	�����A��D�y�y��6�9:�D�	�B�C�C�	C�	
�1�v�0�0�0��)�,-�q�6�2�3�3�	3�
�q�9�9�9�9�1�9�9�9�9��2�3�3�3�	��!�b�&�8�<�<�<�A�	�Q��U��a��A��A�q�!���A��A�1�!��4�4�H��(���r4Tc	���ttdtt|������}t	|��}d}|�rt|j��tk}|t|j��tkz}||jdz
|jzdkz}||j	dkp|j	|jkz}|t|j	|j|j��dkz}||jdkp|j|jkz}t|d��rJ||j
dkp|j
|jkz}|t|j	|j
|j��|jkz}|rtd���|S)a�Construct a DSA key from a tuple of valid DSA components.

    Args:
      tup (tuple):
        A tuple of long integers, with 4 or 5 items
        in the following order:

            1. Public key (*y*).
            2. Sub-group generator (*g*).
            3. Modulus, finite field order (*p*).
            4. Sub-group order (*q*).
            5. Private key (*x*). Optional.

      consistency_check (boolean):
        If ``True``, the library will verify that the provided components
        fulfil the main DSA properties.

    Raises:
      ValueError: when the key being imported fails the most basic DSA validity checks.

    Returns:
      :class:`DsaKey` : a DSA key object
    rFr6rr"zInvalid DSA key components)r+�ziprFrrrr rr!rrErryr"r))�tup�consistency_checkr.�keyr�s     r2rr�sS��2�C�1�3�w��3D�3D�E�E�F�F�H�
��
�
�C��I��;�'���.�.�)�;�	��(���/�/�9�<�<�	��s�u�q�y�C�E�)�a�/�/�	��S�U�a�Z�1�3�5�C�E�>�1�	��S�����s�u�-�-��2�2�	��S�U�a�Z�1�3�5�C�E�>�1�	��3����	;����!��5�s�u���~�5�I���S�U�C�E�3�5�1�1�S�U�:�:�I��7��5�6�6�6��Jr4c����|rtd���t���|dd�����ddkrtd����fd�dD��}t|��S)	Nz-DSA private key already comes with parameters�T)�nr_elements�only_ints_expectedrzNo version foundc� ��g|]
}�|��Sr8r8)r;r<�ders  �r2r=z+_import_openssl_private.<locals>.<listcomp>'s���
1�
1�
1��3�t�9�
1�
1�
1r4)r��r6r��)r)r�decoder)�encodedr�r�r�rs    @r2�_import_openssl_privater!sz���
�J��H�I�I�I�
�-�-�
�
�w�A�$�
�
O�
O�C�
�1�v��{�{��+�,�,�,�
1�
1�
1�
1��
1�
1�
1�C��S�>�>�r4c�`�t|��\}}}|tkrtd���|r|rtd���t���|��j}t
t���|p|����\}}}	||	||f}
t|
��S)NzNo DSA subjectPublicKeyInfozToo many DSA parameters)	rr�r)rr
�value�listrr)rr�r��algoid�encoded_key�
emb_paramsrr r!rr�s           r2�_import_subjectPublicKeyInfor+s���'F�w�'O�'O�#�F�K��
��}�}��6�7�7�7�
�4�*�4��2�3�3�3������K�(�(�.�A��;�=�=�'�'��(<�*�=�=�>�>�G�A�q�!��a��A�,�C��S�>�>�r4c�B�t|��}t|d|��Sr`)rr)rr�r��sp_infos    r2�_import_x509_certr9s!��.�w�7�7�G�'���v�>�>�>r4c��|rtd���tj||��}|dtkrtd���t	���|d��j}tt���|d����\}}}t|||��||||f}t|��S)Nz"PKCS#8 already includes parametersrzNo PKCS#8 encoded DSA keyr6r�)r)r
�unwrapr�rr
rrrrEr)	rr�r�rIr"r r!rr�s	         r2�
_import_pkcs8r?s���
�?��=�>�>�>�
��W�j�)�)�A���t�s�{�{��4�5�5�5������A�a�D�!�!�'�A��;�=�=�'�'��!��-�-�.�.�G�A�q�!��q�!�Q�<�<��A�q�!�
$�C��S�>�>�r4c��ttttf}|D]!}	||||��cS#t$rY�wxYwt	d���)z?Import a DSA key (public or private half), encoded in DER form.�DSA key format is not supported)rrrrr))�key_datar�r��	decodings�decodings     r2�_import_key_derrKsx��)�-�"�� �I�
����	��8�H�j�&�9�9�9�9�9���	�	�	��D�	�����6�
7�
7�7s�/�
<�<c�B��t|��}|�t|��}|�d��r;tjt	|��|��\}}}|rd}t||d��S|�d��r�t
j|�d��d��}g�t|��dkrctjd|dd���d}��|dd|z���|d|zd�}t|��dk�c�dd	kr�fd
�dD��}t|��St|��dkr*t|d��dkrt||d��Std
���)a�Import a DSA key.

    Args:
      extern_key (string or byte string):
        The DSA key to import.

        The following formats are supported for a DSA **public** key:

        - X.509 certificate (binary DER or PEM)
        - X.509 ``subjectPublicKeyInfo`` (binary DER or PEM)
        - OpenSSH (ASCII one-liner, see `RFC4253`_)

        The following formats are supported for a DSA **private** key:

        - `PKCS#8`_ ``PrivateKeyInfo`` or ``EncryptedPrivateKeyInfo``
          DER SEQUENCE (binary or PEM)
        - OpenSSL/OpenSSH custom format (binary or PEM)

        For details about the PEM encoding, see `RFC1421`_/`RFC1423`_.

      passphrase (string):
        In case of an encrypted private key, this is the pass phrase
        from which the decryption key is derived.

        Encryption may be applied either at the `PKCS#8`_ or at the PEM level.

    Returns:
      :class:`DsaKey` : a DSA key object

    Raises:
      ValueError : when the given key cannot be parsed (possibly because
        the pass phrase is wrong).

    .. _RFC1421: http://www.ietf.org/rfc/rfc1421.txt
    .. _RFC1423: http://www.ietf.org/rfc/rfc1423.txt
    .. _RFC4253: http://www.ietf.org/rfc/rfc4253.txt
    .. _PKCS#8: http://www.ietf.org/rfc/rfc5208.txt
    Ns-----r�� r6r�r�rr�c�D��g|]}tj�|����Sr8r�)r;r"r�s  �r2r=zimport_key.<locals>.<listcomp>�s(���I�I�I�q�7�%�h�q�k�2�2�I�I�Ir4)r�rr6r��0r)r	�
startswithrr
r
rr��
a2b_base64�splitr�r��unpackrxrrr))	�
extern_keyr�r�marker�enc_flagr��lengthr�r�s	        @r2rr\s����P��$�$�J����Z�(�(�
����X�&�&�6�"%�*�U�:�->�->�
�"K�"K���f�h��	��J��s�J��5�5�5����[�)�)�
"��'�
�(8�(8��(>�(>�q�(A�B�B�	����)�n�n�q� � ��]�4��2�A�2��7�7��:�F��O�O�I�a��F�
�l�3�4�4�4�!�!�f�*�+�+�.�I��)�n�n�q� � ��A�;�*�$�$�I�I�I�I�L�I�I�I�C��S�>�>�!�
�:������t�J�q�M�2�2�d�:�:��z�:�t�<�<�<�
�6�
7�
7�7r4z1.2.840.10040.4.1)NN)Tr`).�__all__r�r�r��Crypto.Util.py3compatrrr	r
r�Cryptor�	Crypto.IOr
r�Crypto.Hashr�Crypto.Util.asn1rrrrr�Crypto.Math.Numbersr�Crypto.Math.Primalityrrr�Crypto.PublicKeyrrr�objectrr�rrrrrrrr�	importKeyr�r8r4r2�<module>r7sF��2=�
<�
<������
�
�
�
�����H�H�H�H�H�H�H�H�H�H�H�H�H�H������� � � � � � � � ���������������������(�'�'�'�'�'�3�3�3�3�3�3�3�3�3�3�@�@�@�@�@�@�@�@�@�@�@Z"�Z"�Z"�Z"�Z"�V�Z"�Z"�Z"�z2�2�2�jF�F�F�F�R.�.�.�.�p������?�?�?�	�	�	�8�8�8�"C8�C8�C8�C8�N
�	����r4

Zerion Mini Shell 1.0