An S3 Bucket policy that grants permissions to a specific IAM role to perform any Amazon S3 operations on objects in the specified bucket, and denies all other IAM principals.

This policy requires the Unique IAM Role Identifier which can be found using the steps in this blog post.

Missing Parameters
{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Principal": "*",
            "Effect": "Allow",
            "Action": "s3:*",
            "Resource": [
                "arn:aws:s3:::/*",
                "arn:aws:s3:::"
            ],
            "Condition": {
                "StringLike": {
                    "aws:userId": [
                        ":*",
                        ""
                    ]
                }
            }
        },
        {
            "Principal": "*",
            "Effect": "Deny",
            "Action": "s3:*",
            "Resource": [
                "arn:aws:s3:::/*",
                "arn:aws:s3:::"
            ],
            "Condition": {
                "StringNotLike": {
                    "aws:userId": [
                        ":*",
                        ""
                    ]
                }
            }
        }
    ]
}

Actions



Customize Template

Policy Parameters

* Required field