internal: don't override server header

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2022-01-24 22:05:11 +01:00
parent fe39e39dcd
commit e1c0c0b20c
2 changed files with 2 additions and 2 deletions

View File

@ -46,7 +46,7 @@ func NewProxyServer(ac *ak.APIController, portOffset int) *ProxyServer {
rootMux.Use(func(h http.Handler) http.Handler {
return http.HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
h.ServeHTTP(rw, r)
rw.Header().Set("Server", "authentik_proxy2")
rw.Header().Set("X-Powered-By", "authentik_proxy2")
})
})

View File

@ -74,6 +74,6 @@ func (ws *WebServer) proxyErrorHandler(rw http.ResponseWriter, req *http.Request
}
func (ws *WebServer) proxyModifyResponse(r *http.Response) error {
r.Header.Set("server", "authentik")
r.Header.Set("X-Powered-By", "authentik")
return nil
}