1 write to Failure
Microsoft.AspNetCore.Identity (1)
PasskeyAttestationResult.cs (1)
46Failure = failure;
72 references to Failure
IdentitySample.PasskeyConformance (1)
Program.cs (1)
108return Results.BadRequest(new FailedResponse($"Attestation failed: {attestationResult.Failure.Message}"));
Microsoft.AspNetCore.Identity (2)
PasskeyAttestationResult.cs (1)
18[MemberNotNullWhen(false, nameof(Failure))]
SignInManager.cs (1)
573Logger.LogDebug(EventIds.PasskeyAttestationFailed, "Passkey attestation failed: {message}", result.Failure.Message);
Microsoft.AspNetCore.Identity.Test (69)
Passkeys\PasskeyHandlerAttestationTest.cs (69)
45Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 46Assert.Contains("was missing required properties including: 'id'", result.Failure.Message); 64Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 80Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 81Assert.Contains("base64url string", result.Failure.Message); 96Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 97Assert.Contains("was missing required properties including: 'type'", result.Failure.Message); 115Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 130Assert.StartsWith("Expected credential type 'public-key', got 'unexpected-value'", result.Failure.Message); 145Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 146Assert.Contains("was missing required properties including: 'response'", result.Failure.Message); 164Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 180Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 181Assert.Contains("was missing required properties including: 'id'", result.Failure.Message); 199Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 215Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 216Assert.Contains("was missing required properties including: 'name'", result.Failure.Message); 234Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 250Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 251Assert.Contains("was missing required properties including: 'displayName'", result.Failure.Message); 269Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 284Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 285Assert.Contains("was missing required properties including: 'userEntity'", result.Failure.Message); 301Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 302Assert.Contains("was missing required properties including: 'challenge'", result.Failure.Message); 319Assert.StartsWith("The attestation state JSON had an invalid format", result.Failure.Message); 335Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 336Assert.Contains("was missing required properties including: 'clientDataJSON'", result.Failure.Message); 354Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 369Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 385Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 386Assert.Contains("was missing required properties including: 'attestationObject'", result.Failure.Message); 404Assert.StartsWith("The attestation credential JSON had an invalid format", result.Failure.Message); 419Assert.StartsWith("The attestation object had an invalid format", result.Failure.Message); 434Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 435Assert.Contains("was missing required properties including: 'type'", result.Failure.Message); 453Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 471Assert.StartsWith("Expected the client data JSON 'type' field to be 'webauthn.create'", result.Failure.Message); 486Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 487Assert.Contains("was missing required properties including: 'challenge'", result.Failure.Message); 505Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 520Assert.StartsWith("The authenticator response challenge does not match original challenge", result.Failure.Message); 536Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 537Assert.Contains("base64url string", result.Failure.Message); 554Assert.StartsWith("The authenticator response challenge does not match original challenge", result.Failure.Message); 569Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 570Assert.Contains("was missing required properties including: 'origin'", result.Failure.Message); 588Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 603Assert.StartsWith("The authenticator response had an invalid origin ''", result.Failure.Message); 625Assert.StartsWith($"The authenticator response had an invalid origin '{returnedOrigin}'", result.Failure.Message); 642Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 657Assert.StartsWith("The client data JSON had an invalid format", result.Failure.Message); 658Assert.Contains("was missing required properties including: 'status'", result.Failure.Message); 677Assert.StartsWith("Invalid token binding status 'unexpected-value'", result.Failure.Message); 707Assert.StartsWith("The credential is backed up, but the authenticator data flags did not have the 'BackupEligible' flag", result.Failure.Message); 732Assert.StartsWith("The attestation object had an invalid format", result.Failure.Message); 748Assert.StartsWith("The attestation object did not include an attestation statement format", result.Failure.Message); 764Assert.StartsWith("The attestation object did not include an attestation statement", result.Failure.Message); 780Assert.StartsWith("The attestation object did not include authenticator data", result.Failure.Message); 795Assert.StartsWith("The authenticator data had an invalid byte count of 0", result.Failure.Message); 811Assert.StartsWith("The authenticator data had an invalid format", result.Failure.Message); 827Assert.StartsWith("The attested credential data had an invalid byte count of 0", result.Failure.Message); 843Assert.StartsWith("No attested credential data was provided by the authenticator", result.Failure.Message); 858Assert.StartsWith("The authenticator data had an invalid format", result.Failure.Message); 905Assert.StartsWith("The credential public key algorithm does not match any of the supported algorithms", result.Failure.Message); 917Assert.StartsWith("The attestation statement was not valid", result.Failure.Message); 933Assert.StartsWith("Expected the credential ID to have a length between 1 and 1023 bytes", result.Failure.Message); 952result.Failure.Message); 966Assert.StartsWith("The credential is already registered for a user", result.Failure.Message);