S3 Bucket AWS You can't grant public access because Block public access settings are turned on for this account

I want to make S3 bucket public to everyone but I get access denied when I do That and it Says

You can't grant public access because Block public access settings 
are turned on for this account. To determine which settings are 
turned on, check your Block public access settings.

enter image description here

When I go to public access settings everything is turned off.

enter image description here

I did set IAM User and User has AmazonS3FullAccess policy

{
"Version": "2012-10-17",
"Statement": [
    {
        "Effect": "Allow",
        "Action": "s3:*",
        "Resource": "*"
    }
  ]
 }

I did set policy on the bucket

{
"Version": "2012-10-17",
"Id": "Policy1557294263403",
"Statement": [
    {
        "Sid": "Stmt1557294241958",
        "Effect": "Allow",
        "Principal": {
            "AWS": "arn:aws:iam::726051891502:user/borroup-admin"
        },
        "Action": "s3:*",
        "Resource": [
            "arn:aws:s3:::borroup",
            "arn:aws:s3:::borroup/*"
        ]
      }
    ]
 }

I did set CORS configuration editor on the bucket

<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
<AllowedOrigin>*</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
<AllowedMethod>POST</AllowedMethod>
<AllowedMethod>PUT</AllowedMethod>
<MaxAgeSeconds>3000</MaxAgeSeconds>
<AllowedHeader>Authorization</AllowedHeader>
</CORSRule>
</CORSConfiguration>

Answers 1

  • It seems like it has to be unchecked from both places Permissions and Block public access (account settings).

    enter image description here


Related Articles