from https://docs.aws.amazon.com/AmazonS3/latest/userguide/mpuoverview.html#mpuAndPermissions:
> You must be allowed to perform the s3:PutObject action on an object to create a multipart upload request.
but it was calling the verify_bucket_permission() overload which
defaulted to the bucket ARN. pass the object ARN instead, like we do for
RGWPutObj and RGWCompleteMultipart
Fixes: https://tracker.ceph.com/issues/70191
Signed-off-by: Casey Bodley <cbodley@redhat.com>
// add server-side encryption headers
rgw_iam_add_crypt_attrs(s->env, s->info.crypt_attribute_map);
- if (!verify_bucket_permission(this, s, rgw::IAM::s3PutObject)) {
+ if (!verify_bucket_permission(this, s, ARN(s->object->get_obj()),
+ rgw::IAM::s3PutObject)) {
return -EACCES;
}