Package com.yubico.webauthn.data
Class AuthenticatorAssertionResponse
- java.lang.Object
-
- com.yubico.webauthn.data.AuthenticatorAssertionResponse
-
- All Implemented Interfaces:
AuthenticatorResponse
public final class AuthenticatorAssertionResponse extends java.lang.Object implements AuthenticatorResponse
Represents an authenticator's response to a client’s request for generation of a new authentication assertion given the WebAuthn Relying Party's PublicKeyCredentialRequestOptions.getChallenge() challenge} and OPTIONAL PublicKeyCredentialRequestOptions.getAllowCredentials() list of credentials} it is aware of. This response contains a cryptographic signature proving possession of the credential private key, and optionally evidence of user consent to a specific transaction.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AuthenticatorAssertionResponse.AuthenticatorAssertionResponseBuilder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AuthenticatorAssertionResponse.AuthenticatorAssertionResponseBuilder.MandatoryStages
builder()
boolean
equals(java.lang.Object o)
@NonNull ByteArray
getAuthenticatorData()
The authenticator data returned by the authenticator.@NonNull CollectedClientData
getClientData()
AuthenticatorResponse.getClientDataJSON()
parsed as a domain object.@NonNull ByteArray
getClientDataJSON()
The JSON-serialized client data (see §5.10.1 Client Data Used in WebAuthn Signatures (dictionaryCollectedClientData
)) passed to the authenticator by the client in the call to eithernavigator.credentials.create()
ornavigator.credentials.get()
.AuthenticatorData
getParsedAuthenticatorData()
AuthenticatorResponse.getAuthenticatorData()
parsed as a domain object.@NonNull ByteArray
getSignature()
The raw signature returned from the authenticator.java.util.Optional<ByteArray>
getUserHandle()
The user handle returned from the authenticator, or empty if the authenticator did not return a user handle.int
hashCode()
AuthenticatorAssertionResponse.AuthenticatorAssertionResponseBuilder
toBuilder()
java.lang.String
toString()
-
-
-
Method Detail
-
getUserHandle
public java.util.Optional<ByteArray> getUserHandle()
The user handle returned from the authenticator, or empty if the authenticator did not return a user handle. See §6.3.3 The authenticatorGetAssertion Operation.
-
builder
public static AuthenticatorAssertionResponse.AuthenticatorAssertionResponseBuilder.MandatoryStages builder()
-
toBuilder
public AuthenticatorAssertionResponse.AuthenticatorAssertionResponseBuilder toBuilder()
-
getSignature
@NonNull public @NonNull ByteArray getSignature()
The raw signature returned from the authenticator. See §6.3.3 The authenticatorGetAssertion Operation.
-
getParsedAuthenticatorData
public AuthenticatorData getParsedAuthenticatorData()
Description copied from interface:AuthenticatorResponse
AuthenticatorResponse.getAuthenticatorData()
parsed as a domain object.- Specified by:
getParsedAuthenticatorData
in interfaceAuthenticatorResponse
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
getAuthenticatorData
@NonNull public @NonNull ByteArray getAuthenticatorData()
Description copied from interface:AuthenticatorResponse
The authenticator data returned by the authenticator. See §6.1 Authenticator Data.- Specified by:
getAuthenticatorData
in interfaceAuthenticatorResponse
-
getClientDataJSON
@NonNull public @NonNull ByteArray getClientDataJSON()
Description copied from interface:AuthenticatorResponse
The JSON-serialized client data (see §5.10.1 Client Data Used in WebAuthn Signatures (dictionaryCollectedClientData
)) passed to the authenticator by the client in the call to eithernavigator.credentials.create()
ornavigator.credentials.get()
. The exact JSON serialization MUST be preserved, as the hash of the serialized client data has been computed over it.- Specified by:
getClientDataJSON
in interfaceAuthenticatorResponse
-
getClientData
@NonNull public @NonNull CollectedClientData getClientData()
Description copied from interface:AuthenticatorResponse
AuthenticatorResponse.getClientDataJSON()
parsed as a domain object.- Specified by:
getClientData
in interfaceAuthenticatorResponse
-
-