mirror of
https://github.com/minio/minio.git
synced 2025-03-03 07:10:07 -05:00
parent
8eb838bf91
commit
b052bfa79e
@ -375,9 +375,18 @@ var defaultAllowableHTTPMethods = []string{
|
||||
|
||||
// setCorsHandler handler for CORS (Cross Origin Resource Sharing)
|
||||
func setCorsHandler(h http.Handler) http.Handler {
|
||||
commonS3Headers := []string{"Content-Length", "Content-Type", "Connection",
|
||||
"Date", "ETag", "Server", "x-amz-delete-marker", "x-amz-id-2",
|
||||
"x-amz-request-id", "x-amz-version-id"}
|
||||
commonS3Headers := []string{
|
||||
"Date",
|
||||
"ETag",
|
||||
"Server",
|
||||
"Connection",
|
||||
"Accept-Ranges",
|
||||
"Content-Range",
|
||||
"Content-Encoding",
|
||||
"Content-Length",
|
||||
"Content-Type",
|
||||
"x-amz-request-id",
|
||||
}
|
||||
c := cors.New(cors.Options{
|
||||
AllowedOrigins: []string{"*"},
|
||||
AllowedMethods: defaultAllowableHTTPMethods,
|
||||
|
Loading…
x
Reference in New Issue
Block a user