AuthenticateManagementKey Method
AuthenticateManagementKey(Boolean)
Authenticate the management key, throw an exception if the user cancels.
C#
public void AuthenticateManagementKey(bool mutualAuthentication = true)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | mutualAuthentication |
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | There is no |
MalformedYubiKeyResponseException | The YubiKey returned malformed data and authentication, either single or double, could not be performed. |
System.OperationCanceledException | The user canceled management key collection. |
System.Security.SecurityException | Mutual authentication was performed and the YubiKey was not authenticated. |
Remarks
This is the same as TryAuthenticateManagementKey
, except this
method will throw an exception if the KeyCollected
indicates
user cancellation.
See the TryAuthenticateManagementKey(Boolean) method for further documentation on this method.