mirror of
https://github.com/minio/minio.git
synced 2025-11-20 18:06:10 -05:00
acl: Support PUT calls with success for 'private' ACL's (#9000)
Add dummy calls which respond success when ACL's are set to be private and fails, if user tries to change them from their default 'private' Some applications such as nuxeo may have an unnecessary requirement for this operation, we support this anyways such that don't have to fully implement the functionality just that we can respond with success for default ACLs
This commit is contained in:
@@ -117,12 +117,12 @@ func xmlDecoder(body io.Reader, v interface{}, size int64) error {
|
||||
|
||||
// checkValidMD5 - verify if valid md5, returns md5 in bytes.
|
||||
func checkValidMD5(h http.Header) ([]byte, error) {
|
||||
md5B64, ok := h["Content-Md5"]
|
||||
md5B64, ok := h[xhttp.ContentMD5]
|
||||
if ok {
|
||||
if md5B64[0] == "" {
|
||||
return nil, fmt.Errorf("Content-Md5 header set to empty value")
|
||||
}
|
||||
return base64.StdEncoding.DecodeString(md5B64[0])
|
||||
return base64.StdEncoding.Strict().DecodeString(md5B64[0])
|
||||
}
|
||||
return []byte{}, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user