- Categorias:
Funções do sistema (Informações do sistema)
SYSTEM$GET_CMK_CONFIG¶
Retorna informações de configuração para uso com chaves gerenciadas pelo cliente (CMKs) e Tri-Secret Secure.
- Consulte também:
Sintaxe¶
Amazon Web Services e Google Cloud Platform:
SYSTEM$GET_CMK_CONFIG()
Microsoft Azure:
SYSTEM$GET_CMK_CONFIG( '<tenant-id>' )
Argumentos¶
tenant_id
Especifica o identificador exclusivo para o locatário do Azure Key Vault em sua assinatura do Microsoft Azure.
Este valor está no formato GUID, como
b3ddabe4-e5ed-4e71-8827-0cefb99af240
. Você pode encontrar esse valor acessando o Portal e navegando até Key Vault » Overview. Selecione o valor Directory ID.
Retornos¶
A saída depende da plataforma de nuvem que hospeda sua conta Snowflake:
Para Amazon Web Services, um trecho do identificador da instrução (
Sid
) para a política CMK:{"Sid": "Allow use of the key by Snowflake","Effect": "Allow","Principal": {"AWS": "my-arn:name/TRISECRETTEST"},"Action": ["kms:Decrypt","kms:GenerateDataKeyWithoutPlaintext"],"Resource": "arn:aws:kms:us-west-2:736112632310:key/ceab36e4-f0e5-4b46-9a78-86e8f17a0f59"},
Para Microsoft Azure, um URL de consentimento e o nome do principal serviço do Snowflake:
Consent url is: https://login.microsoftonline.com/tenantId/oauth2/authorize?client_id=c03edcfb-19f9-435f-92fa-e8ec9e24f40e&response_type=code and Snowflake Service Principal name is: trisec_cmk_azure"
Para Google Cloud Platform, um comando gcloud:
gcloud kms keys add-iam-policy-binding TriSecretGCPKey --project my-env --location us-west1 --keyring TriSecretTest --member serviceAccount:site-trisecret@my-env.iam.serviceaccount.com --role roles/cloudkms.cryptoKeyEncrypterDecrypter
Notas de uso¶
Somente administradores de conta (usuários com a função ACCOUNTADMIN) podem chamar esta função.
Exemplos¶
Obtenha as informações de configuração para o CMK para sua conta Snowflake em Microsoft Azure:
SELECT SYSTEM$GET_CMK_CONFIG('b3ddabe4-e5ed-4e71-8827-0cefb99af240');