๐ก๏ธ AWS IAM Group Inline Policy allows KMS decryption actions on all KMS keys๐ข
- Contextual name: ๐ก๏ธ Group Inline Policy allows KMS decryption actions on all KMS keys๐ข
- ID:
/ce/ca/aws/iam/group-inline-policy-allows-kms-decrypt-on-all-keys - Tags:
- ๐ข Policy with categories
- ๐ข Policy with type
- ๐ข Production policy
- Policy Type:
COMPLIANCE_POLICY - Policy Categories:
SECURITY
Logicโ
- ๐ง prod.logic.yaml๐ข
Similar Policiesโ
- AWS Security Hub: [KMS.2] IAM principals should not have IAM inline policies that allow decryption actions on all KMS keys
Descriptionโ
Descriptionโ
This policy checks whether an IAM group inline policy allows KMS decryption actions on all AWS KMS keys.
Rationaleโ
IAM group inline policies should follow least privilege and grant access only to the KMS keys that group members explicitly require.
If a group inline policy allows
kms:Decrypt,kms:ReEncryptFrom, or broader KMS decryption-related actions against*or wildcard KMS key ARNs, every principal that inherits the policy through the group can potentially decrypt data protected by keys outside its intended boundary. This increases the blast radius of policy misconfiguration, privilege escalation, and credential misuse.Impactโ
Restricting wildcard KMS access can require updates to shared access models, delegated administration workflows, or legacy group-based permissions that currently rely on broad KMS access. Before tightening the policy, identify the exact KMS keys each group member needs and validate the updated access in a non-production environment when possible.
Auditโ
This policy flags an AWS IAM Group Policy as
INCOMPLIANTwhen all of the following are true:... see more
Remediationโ
Remediationโ
Restrict KMS key scopeโ
Perform the following to update the IAM group inline policy by replacing wildcard KMS resources with the specific KMS key ARNs that should be allowed and, where possible, narrowing broad KMS actions.
From Command Lineโ
Retrieve the current inline policy document:
aws iam get-group-policy \
--group-name {{group-name}} \
--policy-name {{policy-name}}Update the policy document so that KMS decryption permissions are limited to only the specific KMS key ARNs that the group requires.
Apply the updated inline policy:
aws iam put-group-policy \
--group-name {{group-name}} \
--policy-name {{policy-name}} \
--policy-document file://policy.jsonNotesโ
Grant
kms:Decryptandkms:ReEncryptFromonly for the KMS keys that the group inline policy should allow.Where possible, also narrow the allowed actions so the policy does not rely on broad permissions such as
kms:*orkms:ReEncrypt*.