VerifyAttestation Method
VerifyAttestation(ReadOnlyMemory<Byte>)
Use the zero'th public key in the
AttestationCertificates list to verify the
AuthenticatorData
and client data hash using the signature
that is the AttestationStatement.
C#
public bool VerifyAttestation(ReadOnlyMemory<byte> clientDataHash)
Parameters
Type | Name | Description |
---|---|---|
System.ReadOnlyMemory<System.Byte> | clientDataHash | The client data hash sent to the YubiKey to make the credential. |
Returns
System.Boolean
A boolean, true
if the attestation statement (the signature)
verifies, false
otherwise.
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | There is no cert in the attestation certificate list. |
Remarks
If the signature verifies, this method will return true
, and
if it does not verify, it will return false
. If there are no
certificates in the list, this method will throw an exception.