diff --git a/api/layer/object.go b/api/layer/object.go index 4d3c92c..0a2b6de 100644 --- a/api/layer/object.go +++ b/api/layer/object.go @@ -277,7 +277,8 @@ func (n *Layer) PutObject(ctx context.Context, p *PutObjectParams) (*data.Extend if err != nil { return nil, err } - if len(p.ContentMD5) > 0 { + + if !p.Encryption.Enabled() && len(p.ContentMD5) > 0 { headerMd5Hash, err := base64.StdEncoding.DecodeString(p.ContentMD5) if err != nil { return nil, apiErrors.GetAPIError(apiErrors.ErrInvalidDigest)