Description
EBS encryption by default is an account setting for each Region. When it is off, individual volumes can still be encrypted.
Potential impact
New volumes created without encryption can store application data and logs in plaintext.
Remediation
Set enabled = true on aws_ebs_encryption_by_default in each account and Region you use. Check the default KMS key, key permissions and instance support for encryption. Inventory and migrate existing unencrypted volumes and snapshots separately.
Examples
Before
hcl
resource "aws_ebs_encryption_by_default" "default_setting" {
enabled = false
}
After
hcl
resource "aws_ebs_encryption_by_default" "default_setting" {
enabled = true
}
The second configuration enables encryption by default for new volumes and snapshot copies in the AWS provider’s account and Region.