MetaStore
Meta cryptographic provider store.
- class dynamodb_encryption_sdk.material_providers.store.meta.MetaStore(table: boto3.resources.base.ServiceResource, materials_provider: dynamodb_encryption_sdk.material_providers.CryptographicMaterialsProvider)[source]
Bases:
dynamodb_encryption_sdk.material_providers.store.ProviderStore
Create and retrieve wrapped cryptographic materials providers, storing their cryptographic materials using the provided encrypted table.
- Parameters
table (boto3.resources.base.ServiceResource) – Pre-configured boto3 DynamoDB Table object
materials_provider (CryptographicMaterialsProvider) – Cryptographic materials provider to use
- classmethod create_table(client: botocore.client.BaseClient, table_name: str, read_units: int, write_units: int) None [source]
Create the table for this MetaStore.
- get_or_create_provider(material_name: str, version: int) dynamodb_encryption_sdk.material_providers.CryptographicMaterialsProvider [source]
Obtain a cryptographic materials provider identified by a name and version.
If the requested version does not exist, a new one will be created.
- Parameters
- Returns
cryptographic materials provider
- Return type
CryptographicMaterialsProvider
- Raises
InvalidVersionError – if the requested version is not available and cannot be created
- provider(material_name: str, version: Optional[int] = None) dynamodb_encryption_sdk.material_providers.CryptographicMaterialsProvider [source]
Obtain a cryptographic materials provider identified by a name and version.
If the version is provided, an error will be raised if that version is not found.
If the version is not provided, the maximum version will be used.
- Parameters
- Returns
cryptographic materials provider
- Return type
CryptographicMaterialsProvider
- Raises
InvalidVersionError – if the requested version is not found