summaryrefslogtreecommitdiff
path: root/internal/handlers/handler_register_webauthn.go
diff options
context:
space:
mode:
authorJames Elliott <james-d-elliott@users.noreply.github.com>2022-12-27 19:59:08 +1100
committerGitHub <noreply@github.com>2022-12-27 19:59:08 +1100
commitf685f247cfc571a162db24a9d7ff1a1c7612c5dc (patch)
tree712d67b25570bc924deeddcf498e89af6a0fb508 /internal/handlers/handler_register_webauthn.go
parent1c3f650c72e1c03327408656270a8535672bfbbc (diff)
feat(notification): important events notifications (#4644)
This adds important event notifications.
Diffstat (limited to 'internal/handlers/handler_register_webauthn.go')
-rw-r--r--internal/handlers/handler_register_webauthn.go6
1 files changed, 2 insertions, 4 deletions
diff --git a/internal/handlers/handler_register_webauthn.go b/internal/handlers/handler_register_webauthn.go
index 60f89d254..8a3a8cfc0 100644
--- a/internal/handlers/handler_register_webauthn.go
+++ b/internal/handlers/handler_register_webauthn.go
@@ -147,12 +147,10 @@ func WebauthnAttestationPOST(ctx *middlewares.AutheliaCtx) {
userSession.Webauthn = nil
if err = ctx.SaveSession(userSession); err != nil {
ctx.Logger.Errorf(logFmtErrSessionSave, "removal of the attestation challenge", regulation.AuthTypeWebauthn, userSession.Username, err)
-
- respondUnauthorized(ctx, messageMFAValidationFailed)
-
- return
}
ctx.ReplyOK()
ctx.SetStatusCode(fasthttp.StatusCreated)
+
+ ctxLogEvent(ctx, userSession.Username, "Second Factor Method Added", map[string]any{"Action": "Second Factor Method Added", "Category": "Webauthn Credential", "Device Name": "Primary"})
}