> ## Documentation Index
> Fetch the complete documentation index at: https://docs.e6data.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Encryption at rest and customer-managed keys

> Encrypt every disk and store an In-VPC e6data deployment uses with your own AWS KMS or Azure Key Vault key.

How-to guideApplies to: CloudPrem (AWS and Azure)

You can encrypt every disk and store e6data uses with your own key: an AWS KMS customer managed key, or a key in your Azure Key Vault. No change is needed in e6data components for storage. For node disks, the nodes e6data adds must be set to use your key: on AWS with Karpenter, in e6data's node classes; on Azure, e6data sets your Disk Encryption Set. Revoking the key makes e6data's metadata store unreadable within about 10 minutes (measured on Azure).

## Which data uses which key

| Data | Where it lives | AWS: your key | Azure: your key | Required? |
| - | - | - | - | - |
| e6data metadata (query history, result cache, saved sheets, table access times) | Metadata bucket / workspace storage account | Yes. S3 default encryption `aws:kms` with your key, bucket key on | Yes. Storage account encryption with your Key Vault key | Optional |
| Your data lake | Your buckets / storage accounts | Yes. Keep your existing SSE-KMS setup; grant the workspace roles use of the key | Yes. e6data needs no permission on the key | Optional |
| Node OS disks and volumes | EBS / managed disks | Yes. EBS encryption with your key on the node groups or launch template | Yes. Disk Encryption Set (DES) | Optional |
| Local and temporary disks (NVMe spill) | Instance storage | Always encrypted by AWS in hardware (XTS-AES-256), with keys unique to the instance and destroyed when it stops. Your own key can't be applied, and this encryption can't be turned off | Yes, with encryption at host | Optional |
| Kubernetes Secrets objects in your cluster | etcd (managed by your cloud provider) | Yes. EKS secrets encryption with your key | Yes. AKS KMS etcd encryption, including a Key Vault with no public access | Recommended |
| Workspace endpoint TLS certificate | Your cluster | Your own certificate (see [Encryption in transit](https://docs.e6data.com/platform/trust/encryption-in-transit.md)) | Yes, from your Key Vault. The private key must be exportable | Optional |

e6data accesses storage with workload identity (EKS Pod Identity on AWS, AKS Workload Identity on Azure). It uses no storage account keys or SAS tokens, so you can turn shared-key access off on Azure.

> [!WARNING]
>
> Decided at setup: on Azure, the Disk Encryption Set must be set when the AKS cluster is created. It can't be added to an existing cluster.

> [!WARNING]
>
> Decided at setup: on AWS, EKS secrets encryption can't be turned off once on. It can't run while another cluster update is in progress. It takes about 25 minutes.

## Requirements

> [tab] AWS
>
> * The key policy must allow the EC2 Auto Scaling service-linked role (`AWSServiceRoleForAutoScaling`) to use the key, plus `kms:CreateGrant` with the condition `"kms:GrantIsForAWSResource": "true"`. Without it, nodes with encrypted disks fail to launch. This applies to managed node groups.
> * With Karpenter: e6data's node classes and its gp3 StorageClass set no key today, so root volumes follow your account's default EBS encryption and gp3 volumes use the AWS managed key. Your key goes in `blockDeviceMappings` (`encrypted: true` and `kmsKeyID`) on the workspace and platform EC2NodeClasses, and in `kmsKeyId` on the gp3 StorageClass. Karpenter launches nodes with its own role, not the Auto Scaling role, so the key policy needs differ; work this through with e6data.
> * The engine, console and app roles need `kms:Decrypt`, `kms:GenerateDataKey` and `kms:DescribeKey` on the key.
> * If your bucket policy requires an encryption header on every upload, use the `Null`-condition form of the policy below. e6data sends no encryption header, and a strict "require header" policy silently drops query history, result cache and saved sheets.
>
> This form denies an upload only when it carries the wrong header, and lets your bucket's default encryption cover uploads with no header. On the metadata and data buckets, an upload with no header was allowed and stored with your key; an `AES256` header or another key was denied.
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {"Sid":"DenyPutWithNonKmsHeader","Effect":"Deny","Principal":"*","Action":"s3:PutObject",
>  "Resource":"arn:aws:s3:::<BUCKET>/*",
>  "Condition":{"StringNotEquals":{"s3:x-amz-server-side-encryption":"aws:kms"},
>               "Null":{"s3:x-amz-server-side-encryption":"false"}}},
> {"Sid":"DenyPutWithOtherKey","Effect":"Deny","Principal":"*","Action":"s3:PutObject",
>  "Resource":"arn:aws:s3:::<BUCKET>/*",
>  "Condition":{"StringNotEquals":{"s3:x-amz-server-side-encryption-aws-kms-key-id":"<KMS_KEY_ARN>"},
>               "Null":{"s3:x-amz-server-side-encryption-aws-kms-key-id":"false"}}}
> ```
>
> Don't use `StringNotEqualsIfExists` instead. It also denies uploads with no header, so it blocks e6data's writes.

> [tab] Azure
>
> * Your Key Vault needs purge protection.
> * The storage account needs a managed identity with the role *Key Vault Crypto Service Encryption User* on the key.
> * Register the `Microsoft.Compute/EncryptionAtHost` feature on your subscription once, for encryption at host.
> * Every node e6data adds, including autoscaled nodes, must be set to use your Disk Encryption Set. Ask e6data to set it in the install. Without it, autoscaled nodes use Microsoft-managed keys even on a DES cluster.
> * A private Key Vault for AKS KMS needs API-server VNet integration. Cluster creation then takes about 25 minutes instead of about 6.

## Steps

> [tab] AWS
>
> **1. Add the Auto Scaling statement to your key policy**
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "Sid": "AutoScalingEbs",
>   "Effect": "Allow",
>   "Principal": {"AWS": "arn:aws:iam::<ACCOUNT_ID>:role/aws-service-role/autoscaling.amazonaws.com/AWSServiceRoleForAutoScaling"},
>   "Action": ["kms:Encrypt", "kms:Decrypt", "kms:ReEncrypt*", "kms:GenerateDataKey*", "kms:DescribeKey"],
>   "Resource": "*"
> }
> ```
>
> **2. Set default encryption on the metadata bucket**
>
> ```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
> aws s3api put-bucket-encryption --bucket e6-<WORKSPACE_NAME>-metadata \
>   --server-side-encryption-configuration '{"Rules":[{"ApplyServerSideEncryptionByDefault":{"SSEAlgorithm":"aws:kms","KMSMasterKeyID":"<KMS_KEY_ARN>"},"BucketKeyEnabled":true}]}'
> ```
>
> **3. Let the engine, console and app roles use the key**
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {"Effect": "Allow", "Action": ["kms:Decrypt", "kms:GenerateDataKey", "kms:DescribeKey"], "Resource": "<KMS_KEY_ARN>"}
> ```
>
> **4. Encrypt node disks with your key**
>
> Create the e6data node groups with EBS encryption on your key (eksctl `volumeEncrypted: true` and `volumeKmsKeyID: <KMS_KEY_ARN>`, or `KmsKeyId` in a launch template).
>
> **5. Turn on EKS secrets encryption**
>
> Then re-write existing Secrets so they use your key:
>
> ```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
> aws eks associate-encryption-config --cluster-name <CLUSTER> \
>   --encryption-config '[{"resources":["secrets"],"provider":{"keyArn":"<KMS_KEY_ARN>"}}]'
> # wait until the update is Successful
> kubectl get secrets -A -o json | kubectl replace -f -
> ```

> [tab] Azure
>
> **1. Create the cluster with your keys**
>
> Create the AKS cluster with your Disk Encryption Set and, if needed, encryption at host and AKS KMS.
>
> **2. Encrypt the workspace storage account with your key**
>
> ```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
> SA_PRINCIPAL=$(az storage account update -n <STORAGE_ACCOUNT> -g <RG> --assign-identity --query identity.principalId -o tsv)
> az role assignment create --assignee-object-id $SA_PRINCIPAL --assignee-principal-type ServicePrincipal \
>   --role "Key Vault Crypto Service Encryption User" --scope <KEY_VAULT_ID>/keys/<KEY_NAME>
> az storage account update -n <STORAGE_ACCOUNT> -g <RG> \
>   --encryption-key-source Microsoft.Keyvault \
>   --encryption-key-vault https://<KEY_VAULT>.vault.azure.net --encryption-key-name <KEY_NAME>
> ```
>
> **3. Optional: turn off account-key and SAS access**
>
> Then restart the e6data workspace pods (or resume a cluster):
>
> ```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
> az storage account update -n <STORAGE_ACCOUNT> -g <RG> --allow-shared-key-access false
> ```
>
> **4. Set your Disk Encryption Set for e6data nodes**
>
> Ask e6data to set your Disk Encryption Set for the nodes e6data adds.

## Rotation and revocation

| Action | AWS | Azure |
| - | - | - |
| Rotate the key | Use KMS automatic rotation, which keeps the same key ID | Use key rotation instead of replacing keys |
| Revoke or disable the key | See the warning below | Metadata store became unreadable after about 10.6 minutes (`KeyVaultEncryptionKeyNotFound`) |
| Renew the endpoint certificate | See [Encryption in transit](https://docs.e6data.com/platform/trust/encryption-in-transit.md) | The new certificate reached the cluster in about 41 seconds, but the query router kept serving the old one until restarted |

> [!WARNING]
>
> Revoking or deleting the key stops e6data from reading its own metadata. This is how you cut e6data off from its data at rest. Use key rotation, not key replacement, for routine changes.

## Cost impact

* AWS KMS: charges per key and per request. A bucket key reduces request charges on the metadata bucket.
* Azure: Key Vault charges per operation. AKS KMS made about 1,500 encrypt and 1,600 decrypt calls in its first hour on a test cluster.

### Monthly estimate (list prices, November 2026)

| Item | AWS KMS | Azure Key Vault |
| - | - | - |
| Key charge | $1 per key per month. Assumes 2 keys (metadata bucket, cluster secrets and disks) = $2 | Standard tier: no key charge. Premium (HSM-protected) RSA 2048 key: about \$1 per key per month |
| Request charge | $0.03 per 10,000 requests, first 20,000 a month free. With a bucket key, requests stay low: under $1 | $0.03 per 10,000 operations. At the first-hour rate above (about 3,100 calls), the upper bound is about 2.3 million a month = about $7 |
| Total per workspace | About $2 to $3 a month | About $1 to $8 a month |

This is an estimate. It barely changes with cluster size, because a bucket key and the cluster's cached data keys keep request counts low. Check current prices on [AWS KMS pricing](https://aws.amazon.com/kms/pricing/) and [Azure Key Vault pricing](https://azure.microsoft.com/pricing/details/key-vault/).

## Verify

> [tab] AWS
>
> ```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
> aws s3api head-object --bucket e6-<WORKSPACE_NAME>-metadata --key <recent object> \
>   --query '[ServerSideEncryption,SSEKMSKeyId]'
> # expected: "aws:kms", your key ARN
> aws ec2 describe-volumes --filters Name=attachment.instance-id,Values=<node instance id> \
>   --query 'Volumes[].[Encrypted,KmsKeyId]'
> # expected: true, your key ARN
> aws eks describe-cluster --name <CLUSTER> --query cluster.encryptionConfig
> # expected: resources [secrets] with your key ARN
> ```

> [tab] Azure
>
> ```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
> az storage account show -n <STORAGE_ACCOUNT> \
>   --query "{key:encryption.keySource,sharedKey:allowSharedKeyAccess}"
> # expected: "Microsoft.Keyvault", false
> ```

Then resume a cluster in the e6data console, run a query and find it in Query History.

## Troubleshooting

| Symptom | Cause | Fix |
| - | - | - |
| AWS: nodes with encrypted disks never start | The Auto Scaling service-linked role can't use the key | Add the Auto Scaling statement and the `CreateGrant` permission to the key policy |
| AWS: query history, result cache or saved sheets missing, no error | Bucket policy requires an encryption header that e6data doesn't send | Use the `Null`-condition form of the policy |
| AWS: `associate-encryption-config` refused | Another cluster update is in progress | Wait for it to finish, then retry |
| Azure: autoscaled nodes show `EncryptionAtRestWithPlatformKey` | Your Disk Encryption Set isn't set for nodes e6data adds | Ask e6data to set it in the install |
| Azure: workspace fails with `KeyVaultEncryptionKeyNotFound` | Key revoked, disabled or deleted | Restore access to the key |
| Azure: a volume with a DES StorageClass stays pending | The cluster identity had no Reader role on the DES when it was created | Grant Reader on the DES first. A volume that failed before the grant must be re-created |

## Limitations

* Azure: Disk Encryption Set on an existing AKS cluster: Not supported (an Azure limit).
* Azure: picking up a renewed endpoint certificate without a restart: Not supported today.

## See also

* [Encryption in transit](https://docs.e6data.com/platform/trust/encryption-in-transit.md)
* [Security review pack](https://docs.e6data.com/platform/trust/security-review-pack.md)
* [Backup and disaster recovery](https://docs.e6data.com/platform/upgrades/backup-and-disaster-recovery.md)
* Permissions reference: [AWS](https://docs.e6data.com/platform/deploy/aws-cloudprem/permissions-reference.md) · [Azure](https://docs.e6data.com/platform/deploy/azure-cloudprem/permissions-reference.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.