diff --git a/user.go b/user.go index abf58cb..b4eb1e8 100644 --- a/user.go +++ b/user.go @@ -382,7 +382,11 @@ func (u *DynamoUser) FinishLogin(r *http.Request) (*webauthn.Credential, error) credential, err := u.WebAuthnClient.ValidateLogin(u, u.SessionData, parsedResponse) if err != nil { - log.Printf("failed to validate login: %s", err) + var protocolError *protocol.Error + if errors.As(err, &protocolError) { + log.Printf("failed to validate login, ProtocolError: %s, DevInfo: %s", + protocolError.Details, protocolError.DevInfo) + } return &webauthn.Credential{}, fmt.Errorf("failed to validate login: %s", err) }