AmazonEC2ContainerRegistryPowerUser
Summary
Provides full access to Amazon EC2 Container Registry repositories, but does not allow repository deletion or policy changes. The Amazon ECR User Guide says it allows users to read and write to repositories.
Permissions imported from the AWS Managed Policy Reference Guide; other sections reviewed against the listed AWS sources.
Identity
- ARN
arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUser- Default version
- v3
- Created
- Last edited
- Services
- ecr
Control-plane actions (16)
By access level: 2 List, 10 Read, 4 Write.
| Service | Granted | Access levels and limits | Granted by |
|---|---|---|---|
| Elastic Container Registry | 16 of 65 | 2 List, 10 Read, 4 Write; 0 restricted, 0 conditional | ecr:BatchCheckLayerAvailability, ecr:BatchGetImage, ecr:CompleteLayerUpload, ecr:DescribeImageScanFindings, ecr:DescribeImages, ecr:DescribeRepositories, ecr:GetAuthorizationToken, ecr:GetDownloadUrlForLayer, ecr:GetLifecyclePolicy, ecr:GetLifecyclePolicyPreview, ecr:GetRepositoryPolicy, ecr:InitiateLayerUpload and 4 more |
Elastic Container Registry: 16 actions
- ecr:BatchCheckLayerAvailability (Read)
- ecr:BatchGetImage (Read)
- ecr:CompleteLayerUpload (Write)
- ecr:DescribeImageScanFindings (Read)
- ecr:DescribeImages (List)
- ecr:DescribeRepositories (Read)
- ecr:GetAuthorizationToken (Read)
- ecr:GetDownloadUrlForLayer (Read)
- ecr:GetLifecyclePolicy (Read)
- ecr:GetLifecyclePolicyPreview (Read)
- ecr:GetRepositoryPolicy (Read)
- ecr:InitiateLayerUpload (Write)
- ecr:ListImages (List)
- ecr:ListTagsForResource (Read)
- ecr:PutImage (Write)
- ecr:UploadLayerPart (Write)
Data-plane actions (0)
By access level: none.
This policy grants no actions in this plane.
Excluded and conditional actions
No patterns are excluded by NotAction or Deny statements.
Resource scope and attachment
Resource scope across granted actions: all-resources.
Can be attached: Yes, to users, groups and roles.
Why this tier
- Grants 4 write, tagging or permissions-management actions, short of full control of any service.
Guidance
Practical scope
One statement on Resource "*" allows 16 actions: ecr:GetAuthorizationToken, ecr:BatchCheckLayerAvailability, ecr:GetDownloadUrlForLayer, ecr:GetRepositoryPolicy, ecr:DescribeRepositories, ecr:ListImages, ecr:DescribeImages, ecr:BatchGetImage, ecr:GetLifecyclePolicy, ecr:GetLifecyclePolicyPreview, ecr:ListTagsForResource, ecr:DescribeImageScanFindings, ecr:InitiateLayerUpload, ecr:UploadLayerPart, ecr:CompleteLayerUpload and ecr:PutImage.
Use cases
- Let users read and write to Amazon ECR repositories without being able to delete repositories or change their policy documents.
Best practices
- AWS managed policies don't grant least privilege permissions. The IAM User Guide suggests using IAM Access Analyzer to see which permissions principals actually use, then writing a custom policy or generating one with only the required permissions.
Security considerations
- The four write actions are ecr:InitiateLayerUpload, ecr:UploadLayerPart, ecr:CompleteLayerUpload and ecr:PutImage, and they apply to Resource "*", so they cover every repository in the account.
- The action list has no action that creates or deletes repositories, deletes images or sets a repository policy, which matches the guide saying repository deletion and policy changes are not allowed.
- You cannot change the permissions in an AWS managed policy. If AWS updates the policy, the update affects every user, group and role it is attached to.
Assignment guidance
You can attach this policy to your users, groups and roles. The reference page also links to guidance on creating a permission set using AWS managed policies in IAM Identity Center. The Amazon ECR User Guide says you can attach it to your IAM identities. It fits where reading and writing to repositories is intended without repository deletion or policy changes.
Related policies
Same service
- AmazonBraketJobsExecutionPolicy
- AmazonEC2ContainerRegistryFullAccess
- AmazonEC2ContainerRegistryPullOnly
- AmazonEC2ContainerRegistryReadOnly
- AmazonEC2ContainerServiceforEC2Role
- AmazonECSTaskExecutionRolePolicy
- AmazonEKSFargatePodExecutionRolePolicy
- AWSAppRunnerServicePolicyForECRAccess
Same domain
- AmazonEC2ContainerServiceAutoscaleRole
- AmazonEC2ContainerServiceEventsRole
- AmazonECSInstanceRolePolicyForManagedInstances
- AmazonEKSMCPReadOnlyAccess
- AmazonEKSWorkerNodeMinimalPolicy
- AmazonElasticContainerRegistryPublicFullAccess
- AmazonElasticContainerRegistryPublicPowerUser
- AmazonElasticContainerRegistryPublicReadOnly
Frequently asked questions
- When should I attach AmazonEC2ContainerRegistryPowerUser?
- The Amazon ECR User Guide says you can attach it to your IAM identities, and that it allows users to read and write to repositories but not delete repositories or change their policy documents. Attach it where that scope is intended.
- What does AmazonEC2ContainerRegistryPowerUser grant?
- It allows 16 Amazon ECR actions on all resources: twelve read actions, plus ecr:InitiateLayerUpload, ecr:UploadLayerPart, ecr:CompleteLayerUpload and ecr:PutImage.
- What are the security risks of AmazonEC2ContainerRegistryPowerUser?
- The write actions apply to all repositories in the account. Repository deletion and policy changes are not in the action list. AWS managed policies don't grant least privilege permissions, and you must consider the security risk of granting principals more permissions than they need. AWS updates to the policy affect every identity it is attached to.
Policy JSON
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"ecr:GetAuthorizationToken",
"ecr:BatchCheckLayerAvailability",
"ecr:GetDownloadUrlForLayer",
"ecr:GetRepositoryPolicy",
"ecr:DescribeRepositories",
"ecr:ListImages",
"ecr:DescribeImages",
"ecr:BatchGetImage",
"ecr:GetLifecyclePolicy",
"ecr:GetLifecyclePolicyPreview",
"ecr:ListTagsForResource",
"ecr:DescribeImageScanFindings",
"ecr:InitiateLayerUpload",
"ecr:UploadLayerPart",
"ecr:CompleteLayerUpload",
"ecr:PutImage"
],
"Resource": "*"
}
]
}
Version history
Current version v3, edited by AWS on 2019-12-10. Version history is recorded from 2026-11-11. Earlier versions are in the IAM console under Policy versions.
Attach snippets
AWS CLI
aws iam attach-role-policy --role-name ROLE_NAME --policy-arn arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUser
aws iam attach-user-policy --user-name USER_NAME --policy-arn arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUser
aws iam attach-group-policy --group-name GROUP_NAME --policy-arn arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUserCloudFormation
Resources:
ExampleRole:
Type: AWS::IAM::Role
Properties:
AssumeRolePolicyDocument: {} # replace with your trust policy
ManagedPolicyArns:
- arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUserTerraform
resource "aws_iam_role_policy_attachment" "amazonec2containerregistrypoweruser" {
role = aws_iam_role.example.name
policy_arn = "arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUser"
}CDK (TypeScript)
role.addManagedPolicy(
iam.ManagedPolicy.fromAwsManagedPolicyName("AmazonEC2ContainerRegistryPowerUser"),
);Sources
- AmazonEC2ContainerRegistryPowerUser (AWS Managed Policy Reference Guide) (retrieved ; supports summary, practicalScope, securityConsiderations, assignmentGuidance, faqs, useCases)
- AWS managed policies for Amazon ECR (retrieved ; supports summary, useCases, securityConsiderations, assignmentGuidance, faqs)
- Managed policies and inline policies (IAM User Guide) (retrieved ; supports securityConsiderations, faqs)
- AWS managed policies for job functions (IAM User Guide) (retrieved ; supports bestPractices, faqs)