GithubHelp home page GithubHelp logo

Comments (4)

LaurenSpiegel avatar LaurenSpiegel commented on August 10, 2024

I just tested this and it works as expected for me.

Red getting access denied to list black's objects:

lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/black/  --endpoint-url http://localhost:8000

A client error (AccessDenied) occurred when calling the ListObjects operation: Access Denied

Red getting access to list red's objects (make sure you have "/" after "red" in the prefix):

lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/red/  --endpoint-url http://localhost:8000
None
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home/red/file1  2016-08-29T17:18:26.539Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home/red/file2  2016-08-29T17:18:29.350Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF

Also, note for seeing that red has permission on listing the whole bucket or anything with the home/ prefix, you must include a delimiter of "/" in the listing request (red only gets to see the rolled up results). I tested and our behavior is the same as AWS.

Red gets access denied for general listing without delimiter:

lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/  --endpoint-url http://localhost:8000

A client error (AccessDenied) occurred when calling the ListObjects operation: Access Denied

Red gets access for general listing with delimiter:

lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix "" --delimiter / --endpoint-url http://localhost:8000
COMMONPREFIXES  home/
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home    2016-08-29T17:18:12.507Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF
lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/ --delimiter / --endpoint-url http://localhost:8000
COMMONPREFIXES  home/black/
COMMONPREFIXES  home/red/
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home/black  2016-08-29T17:18:35.477Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home/red    2016-08-29T17:18:21.223Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF

from arsenal.

LaurenSpiegel avatar LaurenSpiegel commented on August 10, 2024

Here are the expected results for black as well:

Access denied to list red's objects:

lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/red/  --endpoint-url http://localhost:8000

A client error (AccessDenied) occurred when calling the ListObjects operation: Access Denied
lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/red  --endpoint-url http://localhost:8000

A client error (AccessDenied) occurred when calling the ListObjects operation: Access Denied

Access granted to list black's objects:

lhs:~/ $ aws s3api list-objects --bucket mybucket --prefix home/black/  --endpoint-url http://localhost:8000
None
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home/black/file1    2016-08-29T17:18:41.011Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF
CONTENTS    "d41d8cd98f00b204e9800998ecf8427e"  home/black/file2    2016-08-29T17:18:43.423Z    0   STANDARD
OWNER   test    F962T22H86EDEMBV97U5OYUMTP4E9DERWNGH1XZVVLUKNIMNO4NGPMNQ3O9YMTJF

from arsenal.

dkilcy avatar dkilcy commented on August 10, 2024

I still owe you guys the results of my test.

from arsenal.

rahulreddy avatar rahulreddy commented on August 10, 2024

@dkilcy I am closing the issue for now. Please feel free to re-open if you are able to reproduce the bug.

from arsenal.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.