TKSmartCard
A representation of a smart card.
Declaration
class TKSmartCardOverview
This class provides an interface for managing sessions with a smart card, transmitting requests, and facilitating user interaction.
You can create a TKSmartCard object when a smart card is inserted into a slot, by calling the makeSmartCard() method on the corresponding TKSmartCardSlot object. To start communicating with the smart card, call the beginSession(reply:) method on the TKSmartCard object. Once an exclusive session has been established, you transmit data using the transmit(_:reply:) method. After you’ve finished communicating with a smart card, you call the endSession() method.
If the smart card is physically removed from its slot, the session object becomes invalid, and any further calls to transmit(_:reply:) will return an error. You can use Key-Value Observing on the isValid property to be notified when a smart card is invalidated, due to being removed from the slot or another reason.
Topics
Configuring the Smart Card
Setting the Communication Protocol
Communicating with the Smart Card
Managing User Interaction
userInteractionForSecurePINVerification(_:apdu:pinByteOffset:)userInteractionForSecurePINChange(_:apdu:currentPINByteOffset:newPINByteOffset:)TKSmartCardPINFormatTKSmartCardUserInteractionTKSmartCardUserInteractionForPINOperationTKSmartCardUserInteractionForSecurePINChangeTKSmartCardUserInteractionForSecurePINVerification