ECR repository is not encrypted with customer managed key Affecting ECR service in AWS


Severity

0.0
medium
0
10
Severity Framework
Snyk CCSS
Rule category
Keys and Secrets/ Encryption at Rest

Is your environment affected by this misconfiguration?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
Frameworks
CIS-ControlsCSA-CCMGDPRNIST-800-53SOC-2
  • Snyk IDSNYK-CC-00299
  • creditSnyk Research Team

Description

ECR repository is not encrypted with customer managed key.

How to fix?

Set encryption_configuration.kms_key attribute to customer managed KMS key.

Example Configuration

resource "aws_ecr_repository" "secure" {
  name = "secure-example"

  encryption_configuration {
    encryption_type = "KMS"
    kms_key         = "arnsomekey"
  }
}