Least privilege for AWS Secrets Manager names each secret ARN and its KMS key
Facts read 16 Nov 2026. Page reviewed 16 Nov 2026.
AWS Secrets Manager uses IAM identity-based and resource-based policies, plus the KMS key that encrypts each secret. AWS documentation read on 16 Nov 2026 warns against giving end users the administrator pair. This guide shows a one-secret read grant, wildcard options and what to review.
Open the calculator ยท All services
Secrets Manager access combines IAM policies and KMS permissions
AWS documentation says Secrets Manager uses IAM policies to define who can reach which secrets and what they can do. You can attach identity-based policies to users, groups and roles, or resource-based policies to secrets, and you can use attribute-based access control.
Secrets are encrypted with AWS KMS. The AWS managed key aws/secretsmanager has the correct permissions automatically; a different KMS key needs its own permissions. Rotation functions are Lambda functions that need access to the secret and the target database or service. AWS lists separate permission topics for administrators, access to secrets, rotation functions, encryption keys and replication, and says an application on EC2 can reach a secret through a role on its instance profile. Other services that take roles include Amazon Redshift, AWS Lambda and Amazon ECS.
The identities that call this service (people, services, workloads, third parties) are covered in the AWS service identities guide and the workload identities guide.
The administrator pair is not meant for end users
- SecretsManagerReadWrite together with IAMFullAccess is the documented administrator combination.
- AWS says not to grant administrator permissions to end users, because the permission needed to enable rotation, IAMFullAccess, grants significant permissions that are not appropriate for them.
- A Resource of "*" with secretsmanager:GetSecretValue. AWS example policies name the secret ARN instead.
- Batch grants without limits. AWS shows BatchGetSecretValue with ListSecrets on "*" paired with a statement naming the allowed secret ARNs, so a batch call cannot return others.
Reading one secret needs the secret ARN and the key
For a secret encrypted with a customer managed key, AWS shows two statements. Add secretsmanager:DescribeSecret if the caller also needs metadata.
| Action | Resource | Why |
|---|---|---|
| secretsmanager:GetSecretValue | arn:aws:secretsmanager:us-east-1:123456789012:secret:secretName-AbCdEf | Read the value of one secret |
| kms:Decrypt | arn:aws:kms:us-east-1:123456789012:key/key-id | Decrypt with the customer managed key |
| secretsmanager:DescribeSecret (optional) | the same secret ARN | Read metadata without the value |
Wildcards, ABAC, key denies and replication controls narrow scope
- Wildcards: AWS notes that secret ARNs end in six random characters, so a name followed by the six-character wildcard "??????" matches one secret name exactly.
- A deny on a specific KMS key stops secrets being encrypted with it.
- Attribute-based access control lets tags decide access.
- AWS documents a policy to prevent replication to other Regions and a separate set of permissions for cross-account replication.
- The KMS encryption context for Secrets Manager identifies the secret and its version, so a key policy can bind to it.
Review who can reach each secret
The AWS access control page includes a topic on determining who has permissions to your secrets, and another on reaching secrets from a different account or an on-premises environment. The page ends with topics on identity-based policies and resource-based policies, so both can be reviewed.
Compare the principals that appear with the roles that call GetSecretValue in your logs, and remove the rest. For a secret read by one application, the grant above is the whole requirement; add DescribeSecret only where code reads metadata.
Related pages
Sources
- Authentication and access control for Secrets Manager, read 16 Nov 2026
- Identity-based policies for Secrets Manager, read 16 Nov 2026
- Least-privilege permissions for KMS, read 16 Nov 2026
Last reviewed 16 Nov 2026.