Here’s a sample PUT request that adds an ACL to the finance bucket by using x-amz-grant- headers. The ACL grants read permission to all users, write permission to user pdgrey, and write, read ACL, and write ACL permission to user mwhite.
Request with s3curl command line
./s3curl.pl --id=lgreen --put ~ -- -k "https://europe.hcp.example.com/finance?acl"
-H "x-amz-grant-read:emailAddress=all_users"
-H "x-amz-grant-write:emailAddress=pdgrey, emailAddress=mwhite"
-H "x-amz-grant-read-acp:emailAddress=mwhite"
-H "x-amz-grant-write-acp:emailAddress=mwhite"
Request headers
PUT /finance?acl HTTP/1.1
Host: europe.hcp.example.com
Date: Wed, 20 Mar 2013 15:29:09 +0000
Authorization: AWS bGdyZWVu:RuKD8rwRevmwLo+ZMhF5beGq7Qk=
x-amz-grant-read: emailAddress=all_users
x-amz-grant-write: emailAddress=pdgrey, emailAddress=mwhite
x-amz-grant-read-acp: emailAddress=mwhite
x-amz-grant-write-acp: emailAddress=mwhite
Response headers
HTTP/1.1 200 OK
Date: Wed, 20 Mar 2013 15:29:27 GMT
Server: HCP V7.0.0.16
Content-Length: 0
© 2017 Hitachi Data Systems Corporation. All rights reserved.