If you want to share your Amazon S3 Bucket with your friends, you do not need to share your Access Keys and Secret Access Keys with them. You can share your Amazon S3 Bucket with any user who is registered with Amazon S3. You can limit the access for limited use. To provide permissions on Bucket you can set Bucket ACL.
You can share Bucket with your friends by sending Http PUT Bucket ACL Request to Amazon S3, in one of the two below ways:
Share Bucket with your AWS friend using Amazon S3 REST API - "PUT Bucket ACL" within your software code : If you are a programmer, you can write your own code to share Bucket with your AWS friends using AWS S3 REST or SOAP API. We are showing the REST APIs only in this documentation, you can refer to AWS S3 documentation for SOAP APIs.
Share Bucket with your AWS friend using Bucket Explorer : If you do not want to write code to share Bucket, then you can easily share with Bucket Explorer in few mouse clicks.
1. Share S3 Bucket (PUT Bucket acl) using REST API
To share a Bucket you need to provide access permissions on your Bucket. Using "PUT Bucket ACL" request, you can specify Permission (ACL) on the existing Bucket. You can specify ACL in your request body. To apply this setting, you must have WRITE_ACP permission on the Bucket.
Syntax:
PUT /?acl HTTP/1.1 Host: Bucketname.s3.amazonaws.com Date: date Authorization: signatureValue
If you want to share your Bucket with your friend, you can specify the Email Address of your friend that is registered at Amazon S3 and the permission that you want to give. Also you can share Bucket via Canonical ID of your friend. The valid permission Values are: FULL_CONTROL | WRITE | WRITE_ACP | READ | READ_ACP
2. Share S3 Bucket using Bucket Explorer
Follow the steps below to share and access an Amazon S3 bucket & its files/ folders.
Go to " Bucket Sharing " and choose " Share my Bucket with a friend " option. If you want to share a file(s) instead of the entire Bucket, click on " How to share a file using Amazon S3 "[1]
Bucket Explorer will show you a list of all Buckets in "Share bucket with friends" window.
Choose one Bucket from the Bucket list and click on " OK " button.
Bucket's " Access Control Permissions "[2]window will appear.
Now give the desired permissions to the users and click on Update ACL button.
Note: If you share a Bucket with another S3 users having S3 registered email-id[3].
Click on "Add Access by Email ID/Canonical ID" button in ACL window.
Here you can browse for your friend’s email Id/Canonical Id from the saved address book or you can manually enter your friend’s email Id/canonical Id with whom you want to share your Bucket. The entered/chosen email Id or canonical Id will be added at Bucket Explorer address book if it does not exist.
Give some permission and click on Update ACL button.
See shared icons at the last column in bucket listing.
Follow the steps below to access S3 bucket from your friend's account:
Start Bucket Explorer and connect with your Amazon S3 account.
Click on Tool menu.
Go to " Bucket Sharing " and choose " Access Shared Bucket from a friend's account " option.
Bucket Explorer will prompt you to enter the Third Party bucket[5]name.
Type the bucket name and click on " OK " button.
Now you can see your friend's bucket with " shared bucket " icon in Bucket list box.
You're done. Enjoy accessing Bucket.
Follow these steps to Remove Shared Bucket(s) from Config:
Start Bucket Explorer and connect with your Amazon S3 account.
Click on Tool menu.
Go to " Bucket Sharing " and choose " Remove Shared Bucket(s) from config " option.
It will show a new panel that contains the list of all shared buckets.
Select a bucket name and click on "Remove" button at "Remove Third Party Bucket" panel.
It will remove "Third Party bucket"[5]or Shared Bucket Name from your Bucket listing table.
ˆ How to share a file using Amazon S3 : If you want to share only your desired files instead of the entire Bucket, just click on the Bucket to list the files. After that, select your desired files and give the user the required permission to those files. The files are now ready for sharing. Generate the web URL and send it to your friends. Your files are accessible by your friends via the URLs that you have generated.
ˆ Access Control Permissions : ACP is a mechanism by which Bucket owner can decide Bucket and object accessibility for other users.
ˆ S3 registered email Id : Email by which user is registered with Amazon Web Service (AWS) and Amazon S3.
ˆ Bucket Sharing : Here are more methods for Bucket sharing. Read it and follow the steps.
Right click on the Bucket .
Choose " Update Bucket Access Control List" option.
Give your desired permissions to the users and save it.
ˆ Third Party bucket : A Bucket which we are accessing from other's account is called Friend's Bucket or Third Party Bucket . in Bucket Explorer. Read/Write operations on such Bucket depend on the permissions which can only be set by the Bucket Owner.
Share Amazon S3 Bucket with PUT Bucket ACLIf you want to share your Amazon S3 Bucket with your friends, you do not need to share your Access Keys and Secret Access Keys wi