]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
rgw: DeleteObject supports sigv4 with Transfer-Encoding: chunked
authorCasey Bodley <cbodley@redhat.com>
Thu, 17 Jul 2025 16:41:41 +0000 (12:41 -0400)
committerCasey Bodley <cbodley@redhat.com>
Thu, 17 Jul 2025 17:45:54 +0000 (13:45 -0400)
we don't expect a request body for DeleteObject, so hadn't implemented
its check for the payload hash against the x-amz-content-sha256 header

Fixes: https://tracker.ceph.com/issues/71607
Signed-off-by: Casey Bodley <cbodley@redhat.com>
src/rgw/rgw_rest_s3.cc

index ac1b1e3f54fe87c1d396967112b3195ac16dc057..082144d0833274a96a257265c4bcdf3cf3d7fedc 100644 (file)
@@ -3741,7 +3741,9 @@ int RGWDeleteObj_ObjStore_S3::get_params(optional_yield y)
     bypass_governance_mode = boost::algorithm::iequals(bypass_gov_decoded, "true");
   }
 
-  return 0;
+  // we're not reading any request body, so this should just match
+  // the sha256 hash of an empty buffer
+  return do_aws4_auth_completion();
 }
 
 void RGWDeleteObj_ObjStore_S3::send_response()
@@ -6447,6 +6449,7 @@ AWSGeneralAbstractor::get_auth_data_v4(const req_state* const s,
         case RGW_OP_INIT_MULTIPART: // in case that Init Multipart uses CHUNK encoding
         case RGW_OP_COMPLETE_MULTIPART:
         case RGW_OP_SET_BUCKET_VERSIONING:
+        case RGW_OP_DELETE_OBJ:
         case RGW_OP_DELETE_MULTI_OBJ:
         case RGW_OP_ADMIN_SET_METADATA:
         case RGW_OP_SYNC_DATALOG_NOTIFY: