Home > Enterprise >  Is it possible to restrict access to some folders in a single aws s3 bucket to different users?
Is it possible to restrict access to some folders in a single aws s3 bucket to different users?

Time:12-28

I am building an application to allow users to organize their files/folders.

I am using an AWS S3 bucket under the hood to store the files.

I read that it wasn't a good practice to have a bucket per user architecture since it is not designed for that purpose but I am not comfortable having to check myself that no one access to others files.

Is there a way to restrict some folders (and their subcontent) to some users inside a bucket ?

CodePudding user response:

You can use object tagging and attribute based access control to deny/allow access to objects. A lot of documentation can be found by googling.

ABAC in a nutshell:

  • S3 objects are assigned a tag contaiming a some value (user id, project id, department id)
  • Users are assigned a tag containing a some value (user id, project id, department id)
  • Access is granted if the values match.
  • Related