]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
rgw/sts: fix read_obj_policy permission evaluation 42009/head
authorPritha Srivastava <prsrivas@redhat.com>
Thu, 24 Jun 2021 12:43:28 +0000 (18:13 +0530)
committerPritha Srivastava <prsrivas@redhat.com>
Mon, 22 Nov 2021 09:09:49 +0000 (14:39 +0530)
commit59c46f28d1fc28c731cc9ef86336e8a9ead437a0
tree24539fa1a47e27c10cd42566b22a07af28bd764f
parent070e54178adcf81c520252ebf558a111bda6da72
rgw/sts: fix read_obj_policy permission evaluation
to pass in boost::none for the identity parameter
as identity IAM policies do not have a Principal
for evaluation.
The Principal is the role or the identity to which
the policy is attached.

Also removing boost::optional<const rgw::auth::Identity&> id
paremeter from eval_identity_or_session_policies in all
places, since an identity or a session policy doesnt have
a Principal element. The identity (user or role) or the
session is implicitly the 'Principal' to which the policy
is attached.

fixes: https://tracker.ceph.com/issues/52302

Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
src/rgw/rgw_common.cc
src/rgw/rgw_common.h
src/rgw/rgw_op.cc