mirror of
https://github.com/pgsty/minio.git
synced 2026-09-05 18:16:16 +03:00
Merge remote-tracking branch 'origin/main' into codex/reject-unsupported-checksums
This commit is contained in:
@@ -472,11 +472,17 @@ func completeMultipartOpts(ctx context.Context, r *http.Request, bucket, object
|
||||
}
|
||||
}
|
||||
|
||||
opts.wantChecksumType = r.Header.Get(xhttp.AmzChecksumType)
|
||||
switch opts.wantChecksumType {
|
||||
case "", xhttp.AmzChecksumTypeComposite, xhttp.AmzChecksumTypeFullObject:
|
||||
default:
|
||||
return opts, hash.ErrInvalidChecksum
|
||||
}
|
||||
|
||||
opts.WantChecksum, err = hash.GetContentChecksum(r.Header)
|
||||
if err != nil {
|
||||
return opts, err
|
||||
}
|
||||
opts.wantChecksumTypeSet = r.Header.Get(xhttp.AmzChecksumType) != ""
|
||||
opts.MTime = mtime
|
||||
opts.UserDefined = make(map[string]string)
|
||||
// Transfer SSEC key in opts.EncryptFn
|
||||
|
||||
Reference in New Issue
Block a user