diff options
author | pg9182 <96569817+pg9182@users.noreply.github.com> | 2022-12-03 15:14:15 -0500 |
---|---|---|
committer | pg9182 <96569817+pg9182@users.noreply.github.com> | 2022-12-03 15:14:15 -0500 |
commit | 723278dcae9ba7d223a29147708213ebf6b57550 (patch) | |
tree | 1e481720f23c66a5536263be58ffefe2231e81e2 /pkg/api/api0/client.go | |
parent | 15bbd32f28a69cca2fc82cdbf1f0d860badc7320 (diff) | |
download | Atlas-723278dcae9ba7d223a29147708213ebf6b57550.tar.gz Atlas-723278dcae9ba7d223a29147708213ebf6b57550.zip |
pkg/api/api0: Add more origin_auth logging
Diffstat (limited to 'pkg/api/api0/client.go')
-rw-r--r-- | pkg/api/api0/client.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pkg/api/api0/client.go b/pkg/api/api0/client.go index b5659ed..b8b54cb 100644 --- a/pkg/api/api0/client.go +++ b/pkg/api/api0/client.go @@ -257,10 +257,14 @@ func (h *Handler) handleClientOriginAuth(w http.ResponseWriter, r *http.Request) return } + if acct != nil && username != "" && acct.Username != username { + hlog.FromRequest(r).Info().Uint64("uid", acct.UID).Str("username", username).Str("prev_username", acct.Username).Msg("got updated username from origin") + } if acct == nil { acct = &Account{ UID: uid, } + hlog.FromRequest(r).Info().Uint64("uid", acct.UID).Str("username", username).Msg("created new account") } if username != "" { acct.Username = username |