Skip to content
Snippets Groups Projects
Commit fb63c3d1 authored by ale's avatar ale
Browse files

Add some error logging on saml-server

parent 65b137a4
No related branches found
No related tags found
No related merge requests found
......@@ -180,6 +180,7 @@ func (b *userFileBackend) GetSession(w http.ResponseWriter, r *http.Request, req
// configuration, is also verified at this stage.
username := httpsso.Username(r)
if username == "" {
log.Printf("error: could not retrieve user from SSO")
http.Error(w, "No user found", http.StatusInternalServerError)
return nil
}
......@@ -191,6 +192,7 @@ func (b *userFileBackend) GetSession(w http.ResponseWriter, r *http.Request, req
user, ok := b.users[username]
if !ok {
log.Printf("error: user %s is authenticated but unknown", username)
http.Error(w, "User not found", http.StatusInternalServerError)
return nil
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment