S3_access_error

0

Hi there, I have a s3 bucket where I had access to objects, I changed the s3 bucket policy, after which I have no access to any objects.

My Bucket policy looks like: { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "AWS": "arn:aws:iam::592@@#@$433:root" }, "Action": "s3:", "Resource": [ "arn:aws:s3:::itse%$#%$ey", "arn:aws:s3:::itse%$#%ney/" ] } ] }

error looks like that: This XML file does not appear to have any style information associated with it. The document tree is shown below. <Error> <Code>AccessDenied</Code> <Message>Access Denied</Message> <RequestId>VZPV5P5M21TS0WNM</RequestId> <HostId>DmfNux+XSy9Gz2gHVXTNFVwWxPf6EucNWWbHThaZXRdw8HYFVQQOshuxp6KB8eJP8Y46/PQO8L8=</HostId> </Error>

I have administrator access and what could be the reason?

1 Antwort
2

Though, I'm not sure, what is your exact use case for setting up this bucket policy but here is the correct format of same:

      { 
        "Version": "2012-10-17", 
        "Statement": [ 
          { "Effect": "Allow", 
          "Principal": { 
            "AWS": [
              "arn:aws:iam::592@@#@$433:root" 
            ]},
          "Action": "s3:*", 
          "Resource": [ 
            "arn:aws:s3:::itse%$#%$ey",
            "arn:aws:s3:::itse%$#%ney/*"
            ] 
          } 
        ] 
      }

"*" was missing in your policy for Action and Resource.

For more details, please refer AWS Documentation Bucket policy examples.

Comment here if you have additional questions, happy to help.

profile pictureAWS
EXPERTE
beantwortet vor 4 Monaten
  • Were you able to fix the bucket policy?

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen