Ë
    ùmxiý
  ã                   ó@   — d Z ddlZddlZddlmZ ddlmZ dd„Zdd„Zy)zEHelper functions for loading data from a Google service account file.é    N)Úcrypt)Ú
exceptionsc                 óP  — t        |�|ng «      }|j                  | j                  «       «      }|r3t        j                  dj                  dj                  |«      «      «      ‚|r!t        j                  j                  | «      }|S t        j                  j                  | «      }|S )aØ  Validates a dictionary containing Google service account data.

    Creates and returns a :class:`google.auth.crypt.Signer` instance from the
    private key specified in the data.

    Args:
        data (Mapping[str, str]): The service account data
        require (Sequence[str]): List of keys required to be present in the
            info.
        use_rsa_signer (Optional[bool]): Whether to use RSA signer or EC signer.
            We use RSA signer by default.

    Returns:
        google.auth.crypt.Signer: A signer created from the private key in the
            service account file.

    Raises:
        MalformedError: if the data was in the wrong format, or if one of the
            required keys is missing.
    zGService account info was not in the expected format, missing fields {}.z, )ÚsetÚ
differenceÚkeysr   ÚMalformedErrorÚformatÚjoinr   Ú	RSASignerÚfrom_service_account_infoÚEsSigner)ÚdataÚrequireÚuse_rsa_signerÚkeys_neededÚmissingÚsigners         úX/home/htdocs/ttos/venv/lib/python3.12/site-packages/google/auth/_service_account_info.pyÚ	from_dictr      s”   € ô*  Ð!4‘g¸"Ó=€Kà×$Ñ$ T§Y¡Y£[Ó1€GáÜ×'Ñ'ðß™ §	¡	¨'Ó 2Ó3ó
ð 	
ñ Ü—‘×:Ñ:¸4Ó@ˆð €Mô —‘×9Ñ9¸$Ó?ˆà€Mó    c                 ó¨   — t        j                  | dd¬«      5 }t        j                  |«      }|t	        |||¬«      fcddd«       S # 1 sw Y   yxY w)aó  Reads a Google service account JSON file and returns its parsed info.

    Args:
        filename (str): The path to the service account .json file.
        require (Sequence[str]): List of keys required to be present in the
            info.
        use_rsa_signer (Optional[bool]): Whether to use RSA signer or EC signer.
            We use RSA signer by default.

    Returns:
        Tuple[ Mapping[str, str], google.auth.crypt.Signer ]: The verified
            info and a signer instance.
    Úrzutf-8)Úencoding)r   r   N)ÚioÚopenÚjsonÚloadr   )Úfilenamer   r   Ú	json_filer   s        r   Úfrom_filenamer!   @   sN   € ô 
�‰�˜3¨Ô	1ð U°YÜ�y‰y˜Ó#ˆØ”Y˜t¨WÀ^ÔTÐT÷U÷ Uò Uús   ™%AÁA)NT)Ú__doc__r   r   Úgoogle.authr   r   r   r!   © r   r   ú<module>r%      s#   ðñ Lã 	Û å Ý "ó%ôPUr   