mirror of
https://github.com/pomerium/pomerium.git
synced 2025-05-24 22:47:14 +02:00
core/authorize: result denied improvements (#4952)
* core/authorize: result denied improvements * add authenticate robots.txt * fix tests
This commit is contained in:
parent
61a9bd7c6b
commit
55eb2fa3dc
8 changed files with 19 additions and 91 deletions
|
@ -2,7 +2,6 @@ package proxy
|
|||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"net/http"
|
||||
"net/url"
|
||||
|
@ -43,13 +42,6 @@ func (p *Proxy) registerDashboardHandlers(r *mux.Router) *mux.Router {
|
|||
return r
|
||||
}
|
||||
|
||||
// RobotsTxt sets the User-Agent header in the response to be "Disallow"
|
||||
func (p *Proxy) RobotsTxt(w http.ResponseWriter, _ *http.Request) {
|
||||
w.Header().Set("Content-Type", "text/plain; charset=utf-8")
|
||||
w.WriteHeader(http.StatusOK)
|
||||
fmt.Fprintf(w, "User-agent: *\nDisallow: /")
|
||||
}
|
||||
|
||||
// SignOut clears the local session and redirects the request to the sign out url.
|
||||
// It's the responsibility of the authenticate service to revoke the remote session and clear
|
||||
// the authenticate service's session state.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue