ChangePinCommand Class
Namespace: Yubico.YubiKey.Fido2.Commands Assembly: Yubico.YubiKey.dllChange the YubiKey's FIDO2 application PIN.
public class ChangePinCommand : Object, IYubiKeyCommand<ChangePinResponse>
Implements
Remarks
Upon manufacture, the YubiKey's FIDO2 application has no PIN set as there is no default PIN defined. Many FIDO2 operations are possible by simply inserting the YubiKey and possibly touching the contact. However, it is possible to set the application to require a PIN to perform many of the operations. Use SetPinCommand to set the PIN.
Use this command to change the PIN to a new value. Note that this command is possible only if a PIN is currently set. Note that it is not possible to remove a PIN, other than by resetting the entire application, which will mean losing all credentials as well as removing the PIN.
Constructors
Name | Description |
---|---|
ChangePinCommand(PinUvAuthProtocolBase, ReadOnlyMemory<Byte>, ReadOnlyMemory<Byte>) | Constructs a new instance of ChangePinCommand. |
Properties
Name | Description |
---|---|
Application | Gets the YubiKeyApplication (e.g. PIV, OATH, etc.) to which this command applies. |
Methods
Name | Description |
---|---|
CreateCommandApdu() | Creates a well-formed CommandApdu to send to the YubiKey. |
CreateResponseForApdu(ResponseApdu) | Creates the corresponding IYubiKeyResponse implementation for the current command. |