Skip to content

Commit 7297b9f

Browse files
committed
Switch to info log level
1 parent 175ce98 commit 7297b9f

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

auth/session.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ func (auth *Authenticator) AuthenticateCookie(rq *http.Request, response http.Re
4040
_, err := auth.datastore.Get(auth.DocIDForSession(cookie.Value), &session)
4141
if err != nil {
4242
if base.IsDocNotFoundError(err) {
43-
base.WarnfCtx(auth.LogCtx, "Session not found: %s", base.UD(cookie.Value))
43+
base.InfofCtx(auth.LogCtx, base.KeyAuth, "Session not found: %s", base.UD(cookie.Value))
4444
return nil, base.HTTPErrorf(http.StatusUnauthorized, "Session Invalid")
4545
}
4646
return nil, err
@@ -73,7 +73,7 @@ func (auth *Authenticator) AuthenticateCookie(rq *http.Request, response http.Re
7373
}
7474

7575
if session.SessionUUID != user.GetSessionUUID() {
76-
base.WarnfCtx(auth.LogCtx, "Session no longer valid for user %s", base.UD(session.Username))
76+
base.InfofCtx(auth.LogCtx, base.KeyAuth, "Session no longer valid for user %s", base.UD(session.Username))
7777
return nil, base.HTTPErrorf(http.StatusUnauthorized, "Session no longer valid for user")
7878
}
7979
return user, err

rest/session_api.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,13 +85,13 @@ func (h *handler) getUserFromSessionRequestBody() (auth.User, error) {
8585
}
8686

8787
if user == nil {
88-
base.WarnfCtx(h.ctx(), "Couldn't create session for user %q: not found", base.UD(params.Name))
88+
base.InfofCtx(h.ctx(), base.KeyAuth, "Couldn't create session for user %q: not found", base.UD(params.Name))
8989
return nil, nil
9090
}
9191

9292
authenticated, reason := user.AuthenticateWithReason(params.Password)
9393
if !authenticated {
94-
base.WarnfCtx(h.ctx(), "Couldn't create session for user %q: %s", base.UD(params.Name), reason)
94+
base.InfofCtx(h.ctx(), base.KeyAuth, "Couldn't create session for user %q: %s", base.UD(params.Name), reason)
9595
return nil, nil
9696
}
9797

0 commit comments

Comments
 (0)