s3: do not persist multi part "Response-Content-Disposition" in request header (#7887)

* fix: support standard HTTP headers in S3 multipart upload

* fix(s3api): validate standard HTTP headers correctly and avoid persisting Response-Content-Disposition

---------

Co-authored-by: steve.wei <coderushing@gmail.com>
This commit is contained in:
Chris Lu
2025-12-26 13:21:15 -08:00
committed by GitHub
parent f07ba2c5aa
commit 82dac3df03
2 changed files with 7 additions and 10 deletions

View File

@@ -47,11 +47,8 @@ func ParseS3Metadata(r *http.Request, existing map[string][]byte, isReplace bool
}
}
// Handle Response-Content-Disposition (used in presigned URLs)
// This should be stored as Content-Disposition
if rcd := r.Header.Get("Response-Content-Disposition"); rcd != "" {
metadata["Content-Disposition"] = []byte(rcd)
}
// Do NOT persist Response-Content-Disposition: it is a GET-only
// presigned-download override and must not be stored as upload metadata.
// Object tagging
if tags := r.Header.Get(s3_constants.AmzObjectTagging); tags != "" {