diff --git a/api/layer/object.go b/api/layer/object.go index b8625b3..1b89abf 100644 --- a/api/layer/object.go +++ b/api/layer/object.go @@ -267,7 +267,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)