Change the default object content-type to binary/octet-stream (#11508)

master
Anis Elleuch 4 years ago committed by GitHub
parent b87fae0049
commit 682482459d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      cmd/config/compress/compress.go
  2. 2
      cmd/handler-utils.go

@ -45,7 +45,7 @@ const (
// Include-list for compression.
DefaultExtensions = ".txt,.log,.csv,.json,.tar,.xml,.bin"
DefaultMimeTypes = "text/*,application/json,application/xml"
DefaultMimeTypes = "text/*,application/json,application/xml,binary/octet-stream"
)
// DefaultKVS - default KV config for compression settings

@ -128,7 +128,7 @@ func extractMetadata(ctx context.Context, r *http.Request) (metadata map[string]
// Set content-type to default value if it is not set.
if _, ok := metadata[strings.ToLower(xhttp.ContentType)]; !ok {
metadata[strings.ToLower(xhttp.ContentType)] = "application/octet-stream"
metadata[strings.ToLower(xhttp.ContentType)] = "binary/octet-stream"
}
// https://github.com/google/security-research/security/advisories/GHSA-76wf-9vgp-pj7w

Loading…
Cancel
Save