docs/content/stable/yugabyte-cloud/cloud-secure-clusters/managed-ear.md
{{< page-finder/head text="Encryption at rest" subtle="across different products">}} {{< page-finder/list icon="/icons/database-hover.svg" text="YugabyteDB" url="../../../secure/encryption-at-rest/" >}} {{< page-finder/list icon="/icons/server-hover.svg" text="YugabyteDB Anywhere" url="../../../yugabyte-platform/security/enable-encryption-at-rest/" >}} {{< page-finder/list icon="/icons/cloud-hover.svg" text="YugabyteDB Aeon" current="" >}} {{< /page-finder/head >}}
For added security, you can encrypt your clusters (including backups) using a customer managed key (CMK) residing in a cloud provider Key Management Service (KMS). You grant YugabyteDB Aeon access to the key with the requisite permissions to perform cryptographic operations using the key to secure the databases in your clusters.
You can enable YugabyteDB EAR for a cluster as follows:
Note that, regardless of whether you enable YugabyteDB EAR for a cluster, YugabyteDB Aeon uses volume encryption for all data at rest, including your account data, your clusters, and their backups. Data is AES-256 encrypted using native cloud provider technologies - S3 and EBS volume encryption for AWS, Azure disk encryption, and server-side and persistent disk encryption for GCP. Volume encryption keys are managed by the cloud provider and anchored by hardware security appliances.
Enabling EAR can impact cluster performance. You should monitor your workload after enabling this feature.
{{< tabpane text=true >}}
{{% tab header="AWS" lang="aws" %}}
To use AWS KMS, you need the following:
For more information on AWS KMS, refer to AWS Key Management Service in the AWS documentation.
{{% /tab %}}
{{% tab header="Azure" lang="azure" %}}
Create a key vault using the Azure portal. The following settings are required:
Set the vault permission model as Vault access policy.
Add the application to the key vault access policies with the minimum key management operations permissions of Get and Create (unless you are pre-creating the key), as well as cryptographic operations permissions of Unwrap Key and Wrap Key.
Required permissions are as follows:
"permissions": [ {
"actions": [
"Microsoft.KeyVault/vaults/keys/read",
"Microsoft.KeyVault/vaults/read"
],
"notActions": [],
"dataActions": [
"Microsoft.KeyVault/vaults/keys/read",
"Microsoft.KeyVault/vaults/keyrotationpolicies/read",
"Microsoft.KeyVault/vaults/keys/wrap/action",
"Microsoft.KeyVault/vaults/keys/unwrap/action"
],
"notDataActions": []
} ]
If you are planning to use an existing cryptographic key with the same name, it must meet the following criteria:
In addition, you need the client ID and secret for an application registered in Azure with permission to encrypt and decrypt using the CMK. Refer to Create a new client secret in the Microsoft documentation.
For more information, refer to the Azure Key Vault documentation.
{{% /tab %}}
{{% tab header="GCP" lang="gcp" %}}
To use Cloud KMS, you need the following:
For more information on GCP KMS, refer to Cloud Key Management Service overview in the GCP documentation.
{{% /tab %}}
{{< /tabpane >}}
{{< tabpane text=true >}}
{{% tab header="AWS" lang="aws" %}}
You can enable EAR using a CMK for clusters (database version 2.16.7 and later only) as follows:
{{% /tab %}}
{{% tab header="Azure" lang="azure" %}}
You can enable EAR using a CMK for clusters (database version 2.16.7 and later only) as follows:
https://myvault.vault.azure.net), and the name of the key.{{% /tab %}}
{{% tab header="GCP" lang="gcp" %}}
You can enable EAR using a CMK for clusters (database version 2.16.7 and later only) as follows:
{{% /tab %}}
{{< /tabpane >}}
Click Save when you are done.
YugabyteDB Aeon validates the key and, if successful, starts encrypting the data. Only new data is encrypted with the new key. Old data remains unencrypted until compaction churn triggers a re-encryption with the new key.
To disable cluster EAR, click Disable Encryption at Rest. YugabyteDB Aeon uses lazy decryption to decrypt the cluster.
{{< warning title="Deleting your CMK" >}} If you delete a CMK, you will no longer be able to decrypt clusters encrypted using the key. Before deleting a CMK, make sure that you no longer need it. Retain all CMKs used to encrypt data in backups and snapshots. {{< /warning >}}
To rotate the CMK used for EAR, do the following:
On the cluster Settings tab, select Encryption at rest.
Click Edit CMK Configuration.
For AWS, provide the following details:
For Azure, provide the following details:
https://myvault.vault.azure.net), and the name of the new key.For GCP:
Click Save.
YugabyteDB Aeon uses lazy decryption and encryption to encrypt the cluster using the new key.