Can't access to public bucket of another user

Bug #1510991 reported by Andrey Pavlov
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Swift3
New
Undecided
Unassigned

Bug Description

Amazon allows to list objects and access to public objects from bucket that does not belong to you -
aws s3 ls s3://ec2-downloads/
.....

Also it can be an error -
aws s3 ls s3://testim
A client error (AccessDenied) occurred when calling the ListObjects operation: Access Denied

But swift3 doesn't allow to list public bucket.

Reproduce steps:
1) set admin's acces_key/secret_key to .aws/config (Do not set a region!!! Because with region awscli will use s3v4 protocol which doesn't supported by swift3)

2) create bucket with public-read
aws --debug --endpoint-url http://127.0.0.1:8080/ s3api create-bucket --bucket testi --acl public-read

3) copy any file with public-read to the bucket
aws --debug --endpoint-url http://127.0.0.1:8080/ s3 cp tox.ini s3://testi/ttt --acl public-read

4) check it
aws --debug --endpoint-url http://127.0.0.1:8080/ s3 ls
aws --debug --endpoint-url http://127.0.0.1:8080/ s3 ls s3://testi
aws --debug --endpoint-url http://127.0.0.1:8080/ s3 cp s3://testi/ttt ttt

5) change access_key/secret_key to another user in .aws/config

6) try to list or copy object -
aws --debug --endpoint-url http://127.0.0.1:8080/ s3 ls s3://testi
> A client error (NoSuchBucket) occurred when calling the ListObjects operation: The specified bucket does not exist.
aws --debug --endpoint-url http://127.0.0.1:8080/ s3 cp s3://testi/ttt ttt
> A client error (404) occurred when calling the HeadObject operation: Key "ttt" does not exist

Revision history for this message
Rahul Singh (goyalrahulsingh) wrote :

Is there any update on this issue yet. I am trying to set public-read on an object, and not able to access via any other account.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.