Open JMLX42 opened 6 years ago
Forgot to mention admin also has FULL_CONTROL
on the bucket:
<?xml version="1.0" encoding="UTF-8"?>
<AccessControlPolicy>
<Owner>
<ID>e84fe2aad407ee45651e648603b1c4ab2d97aae7d712a26099475518662a4634</ID>
<DisplayName>admin</DisplayName>
</Owner>
<AccessControlList>
<Grant>
<Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="CanonicalUser">
<ID>e84fe2aad407ee45651e648603b1c4ab2d97aae7d712a26099475518662a4634</ID>
<DisplayName>admin</DisplayName>
</Grantee>
<Permission>FULL_CONTROL</Permission>
</Grant>
<Grant>
<Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="CanonicalUser">
<ID>4efbf4ac1c9fdf6a143e1e189f82ef95bb374f9dff57805d98804f016962a246</ID>
<DisplayName>view3dmodel</DisplayName>
</Grantee>
<Permission>FULL_CONTROL</Permission>
</Grant>
</AccessControlList>
</AccessControlPolicy>
Here are the logs:
127.0.0.1 - - [27/Nov/2017:11:18:35 +0100] "PUT /buckets/4efbf4ac1c9fdf6a/objects/J34%2FJ34Lot%2FJ34Lot2xx%2FJ34Lot227.vue.scene/acl HTTP/1.1" 403 212 "" "curl/7.35.0"
Hi,
How about using s3curl.pl --put <filename> --contentType application/xml
? A complete command could be:
./s3curl.pl --id=admin --put <your xml file path> --contentType application/xml -- -s -v -x localhost:8010 http://s3.amazonaws.com/4efbf4ac1c9fdf6a/J34/J34Lot/J34Lot2xx/J34Lot227.vue.scene
IIRC, s3curl.pl
requires to use --put|--delete|--post
and --contentType
options explicitly to calculate them as a correct signature of AWS Authentication Version 2 when using such http methods except GET
.
Command samples are here.
About --contentType
:
$ curl --contentType
curl: option --contentType: is unknown
How about using s3curl.pl --put
--contentType application/xml ? A complete command could be:
So you mean put my ACL in a temporary file instead of a shell variable passed via stdin ?
So you mean put my ACL in a temporary file instead of a shell variable passed via stdin ?
Yes, I mean so. Perhaps, you could use --put -
to read contents from stdio such as echo $ACL | ./s3curl.pl --put - --contentType application/xml -- <curl options>
since s3curl.pl passes filename
as a param of -T
option of curl...
--contentType application/xml
Again, using --contentType
throws the following error:
curl: option --contentType: is unknown
Hi,
here is was I get when I fetcht he ACL:
As a test, I'm trying to set the exact same ACL on the same object.
Here is what I get:
Why
AccessDenied
when admin hasFULL_CONTROL
?