Skip to content

AWS S3 Penetration Testing

0

I used the AWS Policy Generator to create a policy for my S3 bucket. Unfortunately, I closed the Policy Generator console, so I no longer have access to the actual JSON file. After completing the policy generator requirements, I clicked the optional "Add Condition" feature as an experiment, which correctly generated an "Effect is to Deny" condition in JSON language. After generating the policy, I copied it and pasted it into the bucket's policy editing space and saved it.

Now, I am unable to edit the policy because of the "You don’t have permission to get bucket policy" error, which is an AWS-generated exception under the "Edit" of "Bucket Policy."

Please be advised that I have the option to delete the bucket entirely since it is empty, and create a new bucket with the same name, generating a new policy with the "allow" keyword.

The potential question is, without deleting the current bucket and its existing "deny" policy, which was generated as previously described above, is there any way to edit that bucket policy without deleting the current bucket?

The bucket policy "Edit" button is grayed out and not clickable in this matter.

Snapshoot: You don’t have permission to get bucket policy!

There are no proper tags in relation to the above matter!

The IAM Policy: { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "", "Resource": "" } ] }

2 Answers
2

Have you read this re:Post article which describes how to regain access to a S3 bucket if access has been denied?

AWS
EXPERT
answered a year ago
EXPERT
reviewed a year ago
0

Please be advised the question is related to penetration testing, if a person, such in this case me, can go that extent, it appears he/she knows at least that extent how to edit the policy, but the question is beyond the scope of editing the policy, the subject matter is related to penetration testing which requires some special and extra knowledge of beyond the legacy answer, if I am not wrong.

answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.