Crescendo SDK
Loading...
Searching...
No Matches
CrescendoDLL.PCSC.OATHObject Class Reference

Represents an OATH (Initiative for Open Authentication) credential object for one-time password generation. More...

Public Member Functions

 OATHObject (byte[] data, Version version)
 Initializes a new OATHObject by parsing raw credential data.
 

Properties

bool AddCheckSum [get, set]
 Enables checksum digit for OTP.
 
int CodeDigits [get, set]
 Number of digits in generated OTP.
 
string ContactlessUsage = default! [get, set]
 Contactless interface usage policy.
 
string ContactUsage = default! [get, set]
 Contact interface usage policy.
 
byte[] CounterValue = default! [get, set]
 8-byte counter value for HOTP, OCRA
 
string FriendlyName = default! [get, set]
 Human-readable credential name.
 
HashAlgoValues HashAlgo [get, set]
 Hashing algorithm used for OTP generation.
 
UsePValues HashUsedForOCRAPinOrPassword [get, set]
 Indicates whether the PIN/Password is to be used in OCRA.
 
int KeyLengthInBytes [get, set]
 Cryptographic key length in bytes.
 
bool KeyOrPasswordInitialized [get, set]
 Indicates if key/password material is initialized.
 
OATHModeName OATHMode [get, set]
 OATH operation mode (HOTP/TOTP/OCRA/Static password)
 
string OATHObjectKeyReferenceValue = default! [get, set]
 Key reference identifier for the OATH credential.
 
string OCRASuite = default! [get, set]
 OCRA suite configuration string.
 
string PersonalizationPutKeyACR = default! [get, set]
 Access Control Rule for key personalization.
 
QFormatValues QFormat [get, set]
 Question format for challenge-response in OCRA.
 
int QMaxLength [get, set]
 Maximum challenge length.
 
int TimeStep [get, set]
 Time step interval for TOTP, OCRA.
 
TimeStepUnits TimeStepUnit [get, set]
 Time step units (Seconds/Minutes) for TOTP, OCRA.
 
byte TruncationOffset [get, set]
 Truncation offset for OTP extraction.
 
UseCounterValues UseCounter [get, set]
 Counter usage policy for OCRA.
 
UseSValues UseSessionInformation [get, set]
 Indicates whether the Session Information are to be used in OCRA Suite and what is their size.
 
UseTimeValues UseTime [get, set]
 Time synchronization policy for OCRA.
 

Detailed Description

Represents an OATH (Initiative for Open Authentication) credential object for one-time password generation.

Implements parsing of OATH credentials per RFC 4226 (HOTP) and RFC 6238 (TOTP). Supports both legacy and modern applet versions with different encoding schemes.

Constructor & Destructor Documentation

◆ OATHObject()

CrescendoDLL.PCSC.OATHObject.OATHObject ( byte[]  data,
Version  version 
)
inline

Initializes a new OATHObject by parsing raw credential data.

Parameters
dataBER-TLV encoded OATH configuration
versionAuthenticator applet version

Tag processing:

  • 0x4A: Core OTP parameters
  • 0x48: Key reference mapping
  • 0x4B: OCRA suite configuration
  • 0x4C: User-friendly name
  • 0x4D: Access control policies

Property Documentation

◆ AddCheckSum

bool CrescendoDLL.PCSC.OATHObject.AddCheckSum
getset

Enables checksum digit for OTP.

◆ CodeDigits

int CrescendoDLL.PCSC.OATHObject.CodeDigits
getset

Number of digits in generated OTP.

◆ ContactlessUsage

string CrescendoDLL.PCSC.OATHObject.ContactlessUsage = default!
getset

Contactless interface usage policy.

◆ ContactUsage

string CrescendoDLL.PCSC.OATHObject.ContactUsage = default!
getset

Contact interface usage policy.

◆ CounterValue

byte [] CrescendoDLL.PCSC.OATHObject.CounterValue = default!
getset

8-byte counter value for HOTP, OCRA

◆ FriendlyName

string CrescendoDLL.PCSC.OATHObject.FriendlyName = default!
getset

Human-readable credential name.

Extracted from tag 0x4C. ASCII-encoded string.

◆ HashAlgo

HashAlgoValues CrescendoDLL.PCSC.OATHObject.HashAlgo
getset

Hashing algorithm used for OTP generation.

◆ HashUsedForOCRAPinOrPassword

UsePValues CrescendoDLL.PCSC.OATHObject.HashUsedForOCRAPinOrPassword
getset

Indicates whether the PIN/Password is to be used in OCRA.

◆ KeyLengthInBytes

int CrescendoDLL.PCSC.OATHObject.KeyLengthInBytes
getset

Cryptographic key length in bytes.

◆ KeyOrPasswordInitialized

bool CrescendoDLL.PCSC.OATHObject.KeyOrPasswordInitialized
getset

Indicates if key/password material is initialized.

◆ OATHMode

OATHModeName CrescendoDLL.PCSC.OATHObject.OATHMode
getset

OATH operation mode (HOTP/TOTP/OCRA/Static password)

◆ OATHObjectKeyReferenceValue

string CrescendoDLL.PCSC.OATHObject.OATHObjectKeyReferenceValue = default!
getset

Key reference identifier for the OATH credential.

2-character hex string (e.g., "A1")

Extracted from tag 0x48. Maps to slot positions on the authenticator.

◆ OCRASuite

string CrescendoDLL.PCSC.OATHObject.OCRASuite = default!
getset

OCRA suite configuration string.

Extracted from tag 0x4B. Example: "OCRA-1:HOTP-SHA1-6-QN08-C"

◆ PersonalizationPutKeyACR

string CrescendoDLL.PCSC.OATHObject.PersonalizationPutKeyACR = default!
getset

Access Control Rule for key personalization.

◆ QFormat

QFormatValues CrescendoDLL.PCSC.OATHObject.QFormat
getset

Question format for challenge-response in OCRA.

◆ QMaxLength

int CrescendoDLL.PCSC.OATHObject.QMaxLength
getset

Maximum challenge length.

◆ TimeStep

int CrescendoDLL.PCSC.OATHObject.TimeStep
getset

Time step interval for TOTP, OCRA.

◆ TimeStepUnit

TimeStepUnits CrescendoDLL.PCSC.OATHObject.TimeStepUnit
getset

Time step units (Seconds/Minutes) for TOTP, OCRA.

◆ TruncationOffset

byte CrescendoDLL.PCSC.OATHObject.TruncationOffset
getset

Truncation offset for OTP extraction.

◆ UseCounter

UseCounterValues CrescendoDLL.PCSC.OATHObject.UseCounter
getset

Counter usage policy for OCRA.

◆ UseSessionInformation

UseSValues CrescendoDLL.PCSC.OATHObject.UseSessionInformation
getset

Indicates whether the Session Information are to be used in OCRA Suite and what is their size.

◆ UseTime

UseTimeValues CrescendoDLL.PCSC.OATHObject.UseTime
getset

Time synchronization policy for OCRA.