TryConnectScp03 Method
TryConnectScp03(YubiKeyApplication, StaticKeys, out IScp03YubiKeyConnection)
Attempt to connect to the YubiKey device. The connection will be made over SCP03 (assuming the keys are the ones loaded onto the YubiKey).
public bool TryConnectScp03(YubiKeyApplication application, StaticKeys scp03Keys, out IScp03YubiKeyConnection connection)
Parameters
Type | Name | Description |
---|---|---|
YubiKeyApplication | application | The application to reference on the device. |
StaticKeys | scp03Keys | The SCP03 key set to use in making an SCP03 connection. |
IScp03YubiKeyConnection | connection | Out parameter containing the IYubiKeyConnection instance. |
Returns
Boolean indicating whether the call was successful.
Implements
Remarks
Note that SCP03 works only with SmartCard applications, namely PIV, OATH, and OpenPgp. However, SCP03 is supported only on series 5 YubiKeys with firmware version 5.3 and later, and only the PIV application. If you specify any other application, the connection will likely fail.
Note also that the return is an instance of a class that implements IScp03YubiKeyConnection which is a "subclass" of IYubiKeyConnection.
TryConnectScp03(Byte[], StaticKeys, out IScp03YubiKeyConnection)
Attempt to connect to the YubiKey device. The connection will be made over SCP03 (assuming the keys are the ones loaded onto the YubiKey).
public bool TryConnectScp03(byte[] applicationId, StaticKeys scp03Keys, out IScp03YubiKeyConnection connection)
Parameters
Type | Name | Description |
---|---|---|
System.Byte[] | applicationId | A byte pattern representing the application to reference. |
StaticKeys | scp03Keys | The SCP03 key set to use in making an SCP03 connection. |
IScp03YubiKeyConnection | connection | Out parameter containing the IYubiKeyConnection instance. |
Returns
Boolean indicating whether the call was successful.
Implements
Remarks
Note that SCP03 works only with SmartCard applications, namely PIV, OATH, and OpenPgp. However, SCP03 is supported only on series 5 YubiKeys with firmware version 5.3 and later, and only the PIV application. If you specify any other application, the connection will likely fail.
Note also that the return is an instance of a class that implements IScp03YubiKeyConnection which is a "subclass" of IYubiKeyConnection.