(rds): Encrypt DatabaseCluster (aurora) or DatabaseInstance (rds) storage with AWS-managed key by default (behind feature flag) #32398
Labels
@aws-cdk/aws-rds
Related to Amazon Relational Database
breaking-change
This issue requires a breaking change to remediate.
effort/medium
Medium work item – several days of effort
feature-request
A feature should be added or improved.
p2
Describe the feature
If the user doesn't customize the
DatabaseCluster
orDatabaseInstance
storageEncrypted
property and does not pass a customstorageEncryptionKey
, we should default the value totrue
. This will cause the AWS-managedaws/rds
KMS key to be used.Notes:
storageEncrypted
orstorageEncryptionKey
(as they would be affected by this change in v3).Use Case
Today, if you don't remember to pass
storageEncrypted: true
to yourDatabaseInstance
orDatabaseCluster
, your database's storage will be unencrypted.In almost all cases, your database storage should be encrypted. Here are reasons I think we should use AWS-managed keys by default:
storageEncrypted: false
.Proposed Solution
This applies to
DatabaseCluster
andDatabaseInstance
.If:
storageEncrypted
is not specified in the props; and,storageEncryptionKey
is not specified in the propsThen:
true
, defaultstorageEncrypted
totrue
false
, leavestorageEncrypted
undefined
(existing logic).storageEncrypted
tofalse
to retain compatibility with the new behavior.Other Information
No response
Acknowledgements
CDK version used
2.171.1
Environment details (OS name and version, etc.)
MacOS
The text was updated successfully, but these errors were encountered: