Redirect browser requests returning AccessDenied (#6848)

Anonymous requests from S3 resources returning
AccessDenied should be auto redirected to browser
for login.
This commit is contained in:
Harshavardhana
2018-11-26 12:15:12 -08:00
committed by kannappanr
parent dd092f6c2b
commit dba61867e8
14 changed files with 327 additions and 320 deletions

View File

@@ -351,6 +351,6 @@ func getResource(path string, host string, domain string) (string, error) {
// If none of the http routes match respond with MethodNotAllowed
func notFoundHandler(w http.ResponseWriter, r *http.Request) {
writeErrorResponse(w, ErrMethodNotAllowed, r.URL)
writeErrorResponse(w, ErrMethodNotAllowed, r.URL, guessIsBrowserReq(r))
return
}