google.auth.crypt.base module¶
Base classes for cryptographic signers and verifiers.
-
class
Verifier
[source]¶ Bases:
object
Abstract base class for crytographic signature verifiers.
-
class
FromServiceAccountMixin
[source]¶ Bases:
object
Mix-in to enable factory constructors for a Signer.
-
from_string
(key, key_id=None)[source]¶ Construct an Signer instance from a private key string.
Parameters: Returns: The constructed signer.
Return type: Raises: ValueError
– If the key cannot be parsed.
-
classmethod
from_service_account_info
(info)[source]¶ Creates a Signer instance instance from a dictionary containing service account info in Google format.
Parameters: info ( Mapping
[str
,str
]) – The service account info in Google format.Returns: The constructed signer. Return type: google.auth.crypt.Signer Raises: ValueError
– If the info is not in the expected format.
-
classmethod
from_service_account_file
(filename)[source]¶ Creates a Signer instance from a service account .json file in Google format.
Parameters: filename (str) – The path to the service account .json file. Returns: The constructed signer. Return type: google.auth.crypt.Signer
-