Ensure that there is no wildcard action in an inline KMS key policy

KMS key policy should be setup in such a way that it follows the least privilege principle. Having wildcard in an action may result into a weak security configuration.

Risk Level: High
Cloud Entity: AWS Key Management Service (KMS)
CloudGuard Rule ID: D9.CFT.IAM.30
Covered by Spectral: Yes
Category: Security, Identity, & Compliance


AWS_KMS_Key should not have KeyPolicy.Statement contain-any [ Effect='Allow' and Action='*' ]


From CFT
Set AWS::KMS::Key KeyPolicy.Statement.Action to a restrictive set of actions.


  1. https://docs.aws.amazon.com/kms/latest/developerguide/key-policy-services.html
  2. https://docs.aws.amazon.com/cli/latest/reference/kms/put-key-policy.html

AWS Key Management Service (KMS)

AWS Key Management Service (KMS) is a managed service that makes it easy for you to create and control the encryption keys used to encrypt your data, and uses FIPS 140-2 validated hardware security modules to protect the security of your keys. AWS Key Management Service is integrated with most other AWS services to help you protect the data you store with these services. AWS Key Management Service is also integrated with AWS CloudTrail to provide you with logs of all key usage to help meet your regulatory and compliance needs.

Compliance Frameworks

  • AWS CloudFormation ruleset