What you will be able to do
- Set account parameters with ALTER ACCOUNT and predict which lower levels can override them
- Enable Cortex AI cross-region inference with CORTEX_ENABLED_CROSS_REGION
- Describe the four-level key hierarchy Snowflake uses to encrypt customer data
- Distinguish automatic key rotation from periodic rekeying and enable PERIODIC_DATA_REKEYING
- Register a customer-managed key for Tri-Secret Secure and explain what revoking it does
1.Account parameters and how lower levels override them
Snowflake parameters control how an account, its user sessions and its objects behave, and every parameter has a default value. There are three kinds: account, session and object parameters. You set any of them account-wide with ALTER ACCOUNT SET. What happens next depends on the kind.
| Parameter kind | Effect of setting it on the account | Where it can be overridden |
|---|---|---|
| Account parameter | The value in force for the whole account | Nowhere: it can be set only at the account level |
| Session parameter | A default only | Per user and per session |
| Object parameter | A default only | On the individual object |
To set an account parameter, your role needs the privilege for that parameter. In practice these are ACCOUNTADMIN tasks. Enabling periodic rekeying, for example, is done by a user with ACCOUNTADMIN. Some ALTER ACCOUNT forms work on a different account instead, such as changing its edition. Those belong to the organization administrator.
Checkpoint 1 of 6· Check yourself
A security lead wants periodic rekeying turned on for their own account. The same week, they want a sibling account in the organization moved to Enterprise edition. Who should make each change?
Periodic rekeying is set with ALTER ACCOUNT SET on your own account, and that is an ACCOUNTADMIN task. Changing another account's edition is an ALTER ACCOUNT form that works on a different account, so it belongs to the organization administrator.
“users with the ACCOUNTADMIN role can enable periodic rekeying for the account, using ALTER ACCOUNT and the PERIODIC_DATA_REKEYING parameter”Source: docs.snowflake.com
2.Turning on Cortex AI models from other regions
Many Cortex AI models are not deployed in every region. One account parameter, CORTEX_ENABLED_CROSS_REGION, decides whether a Cortex call can run in another region when your account's region cannot serve it. This parameter only decides where requests can run. Users also need the privileges described in Access control for Cortex AI functions and models.
| Value | Where requests may be processed | Choose it when |
|---|---|---|
| ANY_REGION | Any Snowflake-supported region, on any cloud provider | You want the broadest model selection and highest throughput |
| AWS_GLOBAL, AZURE_GLOBAL, GCP_GLOBAL | Only within the named cloud provider | Inference must stay on one provider's network |
| AWS_US, AWS_EU, AZURE_EU and similar | Only within the named provider and geography | Inference must also stay in one geography |
| DISABLED | Only the account's home region | You have strict data residency rules and can accept fewer models |
ALTER ACCOUNT SET CORTEX_ENABLED_CROSS_REGION = 'AWS_GLOBAL';Cross-region inference does not move your stored data. Only the prompt and the response pass through the processing region, and only while the request runs. Nothing is persisted there. Credits are charged in your account's region, with no data egress charges. If the parameter was never set, the account inherits a default. To see the value in effect, run SHOW PARAMETERS LIKE 'CORTEX_ENABLED_CROSS_REGION' IN ACCOUNT. If you have residency requirements, set the value explicitly.
Checkpoint 2 of 6· Check yourself
An administrator runs ALTER ACCOUNT SET CORTEX_ENABLED_CROSS_REGION = 'ANY_REGION' so that analysts can use a model that isn't deployed in the account's home region. Which statement about the result is correct?
CORTEX_ENABLED_CROSS_REGION only decides where a request can run. Access to Cortex functions is controlled by separate privileges. Only the prompt and response pass through the other region, nothing is stored there, and credits are charged in the account's own region with no egress charges.
“Access to Snowflake Cortex AI Functions is gated by an account-level privilege and one of several database roles.”Source: docs.snowflake.com
3.How Snowflake encrypts customer data
All customer data is encrypted by default with AES, and you do not configure or manage any of it. The keys form a hierarchy in which each parent key encrypts, or wraps, the keys one level below it. There are four levels:
- The root key, stored in a cloud-hosted hardware security module (HSM)
- Account master keys, one per account
- Table master keys, one per table
- File keys, one per file
The hierarchy has two purposes. Separate account master keys isolate each account, adding a layer on top of access control in a multi-tenant service. Narrow keys also limit the damage if a key is exposed: a table master key covers one table and a file key covers one file. On AWS and Azure, Snowflake creates and stores the root key in the HSM. On Google Cloud it uses Cloud KMS, in multi-tenant HSM partitions. Unwrapping happens from the top down. The key in the HSM unwraps the account master key, which then decrypts the table master key in software.
Checkpoint 3 of 6· Match them up
Snowflake's encryption hierarchy has four levels of keys. Match each key to its place in the hierarchy.
Tap a term, then the definition that fits it.
Each parent key wraps the level below it. The root key in the HSM sits at the top. Separate account master keys keep accounts apart. Below them, each key covers less: a table master key covers one table and a file key covers one file, which limits the damage if any one key is exposed.
“For example, a table master key encrypts a single table. A file key encrypts a single file.”Source: docs.snowflake.com
Sources3
4.Key rotation versus periodic rekeying
Rotation retires a key but does not re-encrypt anything. Suppose TMK v1 protects a table's April data. In May it is retired and a new random key, TMK v2, encrypts everything inserted after that, while v1 stays available only to decrypt the April data. In June v3 takes over the same way. Only the current active key is ever used to encrypt.
Rekeying finishes the job. With periodic rekeying enabled, once a retired table key is more than a year old, Snowflake creates a new key and re-encrypts all the data the old key protected. The old key is then destroyed. Together, rotation and rekeying limit any key's lifetime to one year. Rekeying is also a chance for Snowflake to move to larger key sizes or better algorithms.
| Aspect | Key rotation | Periodic rekeying |
|---|---|---|
| Moves a key from | Active to retired | Retired to destroyed |
| Trigger | Key older than 30 days | Retired key older than one year |
| Re-encrypts existing data | No | Yes |
| Configuration | None, always on | PERIODIC_DATA_REKEYING, Enterprise Edition, set by ACCOUNTADMIN |
ALTER ACCOUNT SET PERIODIC_DATA_REKEYING = TRUE;Rekeying runs online in the background, with no downtime and no performance impact on workloads, because storage and compute are separate. It does not change Time Travel or Fail-safe retention periods. It does cost something: rekeyed files are charged 7 days of Fail-safe storage, because both the old-key copy and the new-key copy sit in Fail-safe during that window.
Checkpoint 4 of 6· Fill the gap
A compliance team on Enterprise Edition needs data protected by retired keys older than one year to be re-encrypted under new keys. Automatic rotation is already running. Which parameter should the ACCOUNTADMIN set?
ALTER ACCOUNT SET ? = TRUE;Key rotation is always on and needs no setting, but it only retires keys and never re-encrypts existing data. Re-encrypting data whose retired key is more than a year old is periodic rekeying, which an ACCOUNTADMIN turns on with PERIODIC_DATA_REKEYING.
Source: docs.snowflake.comSources3
5.Tri-Secret Secure and the customer-managed key
Tri-Secret Secure combines a key Snowflake maintains with a customer-managed key (CMK) that you keep in your cloud provider's key service. On AWS that is AWS KMS, on Google Cloud it is Cloud KMS, and on Azure it is Azure Key Vault. The two keys form a composite master key, and together with user authentication that gives three layers of protection. The composite key takes the place of the account master key, wrapping every key below it. It never encrypts raw data directly. File keys still do that.
Setting it up starts with self-registration and ends with Snowflake Support:
- Create the CMK in your cloud provider's KMS.
- Call
SYSTEM$REGISTER_CMK_INFOto register it. - Call
SYSTEM$GET_CMK_INFOto check the registration details. - Call
SYSTEM$GET_CMK_CONFIGto generate the policy information for your provider. On Azure, pass the tenant_id. - Use that output on the provider side to authorize the key.
- Call
SYSTEM$VERIFY_CMK_INFOto confirm Snowflake can reach the key. - Ask Snowflake Support to enable Tri-Secret Secure for the specific account.
SYSTEM$GET_CMK_INFO reports progress throughout. It returns "is being activated" while the first rekeying runs, then "is activated". After you switch to a different CMK, it returns "is being rekeyed" while data moves to the new key.
Snowflake picks up the new CMK version the next time it rotates the account master key, which happens automatically every 30 days. After that, newly created files are encrypted under the new version, and existing files are still decrypted with the older versions. Never delete or revoke an older version: Snowflake cannot decrypt data under a deleted key.
You are responsible for the key. If the CMK is revoked or disabled, Snowflake can no longer decrypt the account's data. To change keys on purpose, register a new CMK with the same steps and coordinate the switch with Support. Keep the current CMK accessible until Support confirms it is safe to remove.
Checkpoint 5 of 6· Put it in order
Your team wants Tri-Secret Secure on its production account. Arrange the setup steps from first to last.
- 1.Confirm Snowflake can reach the key with SYSTEM$VERIFY_CMK_INFO
- 2.Generate the policy information for the provider with SYSTEM$GET_CMK_CONFIG
- 3.Create the customer-managed key in the cloud provider's key management service
- 4.Register the key in Snowflake with SYSTEM$REGISTER_CMK_INFO
- 5.Use that output on the provider side to authorize the key
- 6.Ask Snowflake Support to enable Tri-Secret Secure for the specific account
You do the self-registration steps yourself: create, register, generate the policy, authorize and verify. Only after that does Snowflake Support turn Tri-Secret Secure on for the account. Support cannot activate a key that has not been registered and authorized.
“As the customer, you do the following actions: Create the CMK. Register the CMK. Generate information for the cloud provider. Apply the KMS policy.”Source: docs.snowflake.com
Checkpoint 6 of 6· Check yourself
Once Tri-Secret Secure is active, where does the composite master key sit in Snowflake's key hierarchy?
The composite master key acts as the account master key and wraps every key below it. It never encrypts raw data. Because the CMK is part of it, revoking or disabling the CMK leaves Snowflake unable to decrypt the account's data.
“This composite master key acts as an account master key by wrapping all of the keys in your account hierarchy.”Source: docs.snowflake.com
Sources
(6)
Every claim above is drawn from one of these pages, quoted as it was written on the date shown.
- 1.
“Session and object parameters that are set using this command serve only as defaults”
↩︎ Account parameters and how lower levels override them“Account parameters can be set only at the account level.”
↩︎ Account parameters and how lower levels override them - 2.
“if you are using a role that has been granted the privilege to set the parameter.”
↩︎ Account parameters and how lower levels override them“Used to enable cross-region processing of Snowflake Cortex calls in a different region if the call cannot be processed in your account region.”
↩︎ Turning on Cortex AI models from other regions - 3.
“users with the ACCOUNTADMIN role can enable periodic rekeying for the account”
↩︎ Account parameters and how lower levels override them“All Snowflake customer data is encrypted by default.”
↩︎ How Snowflake encrypts customer data“the hierarchical key model isolates every account with the use of separate account master keys.”
↩︎ How Snowflake encrypts customer data“On AWS and Azure, Snowflake uses the HSM to create and store the root key.”
↩︎ How Snowflake encrypts customer data“rekeying ensures that a key is transferred from its retired state to being destroyed.”
↩︎ Key rotation versus periodic rekeying“when the retired encryption key for a table is older than one year, Snowflake automatically creates a new encryption key”
↩︎ Key rotation versus periodic rekeying“For these files, 7 days of Fail-safe protection is charged.”
↩︎ Key rotation versus periodic rekeying“Deleting a rotated key can lead to data loss.”
↩︎ Tri-Secret Secure and the customer-managed key“When retired, the key is used solely to decrypt customer data and is only available for accessing the data.”
↩︎ Exam trap 1“Snowflake incorporates the new CMK version the next time it rotates its internal Account Master Key (AMK), which occurs automatically, every 30 days.”
↩︎ Exam trap 3“users with the ACCOUNTADMIN role can enable periodic rekeying for the account, using ALTER ACCOUNT and the PERIODIC_DATA_REKEYING parameter”
↩︎ Checkpoint“For example, a table master key encrypts a single table. A file key encrypts a single file.”
↩︎ Checkpoint“Keys in the Snowflake-managed key hierarchy are automatically rotated by Snowflake when they are more than 30 days old.”
↩︎ Prediction - 4.
“Your customer data remains stored only in the region where your account is located.”
↩︎ Turning on Cortex AI models from other regions“Credits are consumed in your requesting region, regardless of where the request is processed.”
↩︎ Turning on Cortex AI models from other regions - 5.
“This composite master key acts as an account master key by wrapping all of the keys in your account hierarchy.”
↩︎ Tri-Secret Secure and the customer-managed key“If the customer-managed key (CMK) in the composite master key hierarchy is revoked, your data can no longer be decrypted by Snowflake.”
↩︎ Tri-Secret Secure and the customer-managed key“call the SYSTEM$REGISTER_CMK_INFO system function to register your CMK with the KMS integration.”
↩︎ Tri-Secret Secure and the customer-managed key“The composite master key is never used to encrypt raw data.”
↩︎ Exam trap 2“As the customer, you do the following actions: Create the CMK. Register the CMK. Generate information for the cloud provider. Apply the KMS policy.”
↩︎ Checkpoint
Also cited
“Access to Snowflake Cortex AI Functions is gated by an account-level privilege and one of several database roles.”
↩︎ Checkpoint