Currently, it does not appear that the s3 functionality can delete bucket
policies. There is a method to get and set the policy, however.
I added the following to bucket.py to implement delete bucket policy
functionality:
def delete_policy(self, headers=None):
response = self.connection.make_request('DELETE', self.name,
data='/?policy',
query_args='policy',
headers=headers)
body = response.read()
if response.status >= 200 and response.status <= 204:
return True
else:
raise self.connection.provider.storage_response_error(
response.status, response.reason, body)
For reference, see:
http://docs.amazonwebservices.com/AmazonS3/latest/dev/index.html?deletebucketpol
icy.html.
Thanks,
Jason
Original issue reported on code.google.com by jason.b....@gmail.com on 3 Aug 2011 at 11:31
Original issue reported on code.google.com by
jason.b....@gmail.com
on 3 Aug 2011 at 11:31