PinProtectedData ClassNamespace: Yubico.YubiKey.Piv.Objects Assembly: Yubico.YubiKey.dll
Use this class to process a specific set of PIN-protected data stored in the PRINTED data object.
public sealed class PinProtectedData : PivDataObject, IDisposable
Some Data Objects are retrievable only in a session where the PIN has been verified. Hence, that data is PIN-protected. This class will be able to process data stored in one such Data Object. The data this class can process is specified by its properties.
See the User's Manual entry on PIV data objects for a description of the details of how this class works.
This class specifies the
DefinedDataTag to be
which is the data tag for the PRINTED storage area. The reason is that
the PRINTED area requires the PIN to read. The data is stored in this
object and when it is needed, simply retrieve it and use it. In order to
retrieve, though, PIN verification is required, so in this way the data
This class does not allow changing the
DataTag. That is, it is
possible to store the data in this set only in the PRINTED area.
This class is different from other
PivDataObjects. Most such
classes store information encoded as the PIV standard defines it.
However, this class stores the elements specified by
PinProtectedDataType following a definition that is not the PIV
standard for PRINTED.
Note that this object can accept or decode only elements for which there is a property.
Build a new object. This will not get the PIN-protected data from the YubiKey, it will only build an "empty" object.
The management key that will be PIN-protected. If there is no management key, this will be null.
Releases any unmanaged resources and overwrites any sensitive data.
Build the encoding of the data.
Get the defined data tag. This is the data tag that the PIV standard or Yubico defines to specify the given data object.
Override the base class. This class does not allow alternate DataTags. The only allowed tag is the defined.
Try to decode the data given according to the format specified for
the data object. If successful, return