From e97b7d642618bf041acc573e2313f19dd441131e Mon Sep 17 00:00:00 2001 From: Abhishek Lekshmanan Date: Tue, 8 Oct 2019 15:18:35 +0200 Subject: [PATCH] rgw: Fix IgnorePublicACLs for bucket ACLs Currently Bucket ACLs with IgnorePublicACLs were broken this should fix that Signed-off-by: Abhishek Lekshmanan --- src/rgw/rgw_common.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/rgw/rgw_common.cc b/src/rgw/rgw_common.cc index b38f3448ca0..350de785bd9 100644 --- a/src/rgw/rgw_common.cc +++ b/src/rgw/rgw_common.cc @@ -1198,8 +1198,10 @@ bool verify_bucket_permission_no_policy(const DoutPrefixProvider* dpp, struct pe if ((perm & (int)s->perm_mask) != perm) return false; - if (bucket_acl->verify_permission(dpp, *s->identity, perm, perm, - s->get_referer())) + if (bucket_acl->verify_permission(dpp, *s->auth.identity, perm, perm, + s->info.env->get("HTTP_REFERER"), + s->bucket_access_conf && + s->bucket_access_conf->ignore_public_acls())) return true; if (!user_acl) -- 2.39.5