Skip to content

Commit 6db0369

Browse files
authored
Merge pull request ceph#64290 from cbodley/wip-49135
rgw/s3: fix PutObject's canned_acl comparisons for BlockPublicAcls Reviewed-by: Adam Emerson <[email protected]> Reviewed-by: Abhishek Lekshmanan <[email protected]>
2 parents c0c035e + e9eedec commit 6db0369

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/rgw/rgw_op.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4101,9 +4101,9 @@ int RGWPutObj::init_processing(optional_yield y) {
41014101

41024102
// reject public canned acls
41034103
if (s->bucket_access_conf && s->bucket_access_conf->block_public_acls() &&
4104-
(s->canned_acl.compare("public-read") ||
4105-
s->canned_acl.compare("public-read-write") ||
4106-
s->canned_acl.compare("authenticated-read"))) {
4104+
(s->canned_acl == "public-read" ||
4105+
s->canned_acl == "public-read-write" ||
4106+
s->canned_acl == "authenticated-read")) {
41074107
return -EACCES;
41084108
}
41094109

0 commit comments

Comments
 (0)