Skip to content

Commit 7307a3d

Browse files
authored
Merge pull request ceph#61901 from cbodley/wip-69936
rgw/cksum: GetObject omits checksum headers for Range requests Reviewed-by: Matt Benjamin <[email protected]>
2 parents ac5f785 + 53098ba commit 7307a3d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/rgw/rgw_rest_s3.cc

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,10 @@ int RGWGetObj_ObjStore_S3::send_response_data(bufferlist& bl, off_t bl_ofs,
501501
}
502502
}
503503

504-
if (checksum_mode) {
504+
// omit the stored full-object checksum headers if a Range is requested
505+
// TODO: detect when a Range coincides with a single part of a multipart
506+
// upload, and return its part checksum?
507+
if (checksum_mode && !range_str) {
505508
if (auto i = attrs.find(RGW_ATTR_CKSUM); i != attrs.end()) {
506509
try {
507510
rgw::cksum::Cksum cksum;

0 commit comments

Comments
 (0)