24#include "keypop/reader/selection/spi/IsoSmartCard.hpp"
31using keypop::reader::selection::spi::IsoSmartCard;
161 virtual const std::vector<uint8_t>&
getDfName()
const = 0;
316 virtual const std::shared_ptr<ElementaryFile>
331 virtual const std::shared_ptr<ElementaryFile>
345 virtual const std::vector<std::shared_ptr<ElementaryFile>>&
getFiles()
const
544 virtual const std::vector<std::shared_ptr<SvDebitLogRecord>>
548 inline operator std::string();
553 os <<
"PRODUCT_TYPE: ";
563 os <<
"PRIME_REVISION_1";
566 os <<
"PRIME_REVISION_2";
569 os <<
"PRIME_REVISION_3";
Extends the IsoSmartCard interface of the "Keypop Reader API" to provide additional functionality spe...
virtual const std::shared_ptr< ElementaryFile > getFileByLid(const uint16_t lid) const =0
Returns a reference to the ElementaryFile that has the provided LID value.
virtual const std::vector< std::uint8_t > & getCaCertificate() const =0
Returns the CA certificate.
virtual bool isDfInvalidated() const =0
Tells if the current DF is invalidated or not.
virtual const std::vector< std::uint8_t > & getCardCertificate() const =0
Returns the card certificate.
ProductType
All Calypso Card products supported by this API.
@ PRIME_REVISION_1
Card Calypso Prime revision 1.x.
@ UNKNOWN
Application type is equal to 0 or FFh or if the data provided by the selection process is not properl...
@ PRIME_REVISION_2
Card Calypso Prime revision 2.x.
@ PRIME_REVISION_3
Card Calypso Prime revision 3.x.
@ BASIC
Card Calypso Basic.
@ LIGHT
Card Calypso Light.
virtual int getPinAttemptRemaining() const =0
Gives the number of erroneous PIN presentations remaining before blocking.
virtual const std::vector< uint8_t > & getDfName() const =0
Gets the DF name as an array of bytes.
virtual uint8_t getApplicationSubtype() const =0
Gets the Application Subtype that provides a reference to the file structure of the Calypso DF.
virtual const std::vector< uint8_t > getApplicationSerialNumber() const =0
Gets the Calypso application serial number as an array of bytes.
virtual const ProductType & getProductType() const =0
Gets the card product type.
virtual const std::shared_ptr< SvLoadLogRecord > getSvLoadLogRecord()=0
Gets a reference to the last SvLoadLogRecord.
virtual uint8_t getPlatform() const =0
Gets the platform identification byte which is the reference of the chip.
virtual int getTransactionCounter() const =0
Returns the transaction counter value provided in the output data of the last successful "Open Secure...
virtual bool isExtendedModeSupported() const =0
Indicates whether the Extended Mode is supported or not (since rev 3.2).
virtual int getSvBalance() const =0
Gets the current SV balance value.
virtual bool isPkiModeSupported() const =0
Indicates whether the Public Key Authentication is supported or not (since rev 3.3).
virtual const std::shared_ptr< SvDebitLogRecord > getSvDebitLogLastRecord()=0
Gets a reference to the last SvDebitLogRecord.
virtual const std::vector< uint8_t > getTraceabilityInformation() const =0
Gets the traceability information of the product.
virtual bool isHce() const =0
Indicates if the card is a Calypso HCE (Host Card Emulation) .
virtual const std::vector< std::uint8_t > & getCardPublicKey() const =0
Returns the card public key.
virtual bool isSvFeatureAvailable() const =0
Indicates whether the card has the Calypso Stored Value feature.
virtual const std::shared_ptr< ElementaryFile > getFileBySfi(const uint8_t sfi) const =0
Returns a reference to the ElementaryFile that has the provided SFI.
virtual const std::vector< std::shared_ptr< SvDebitLogRecord > > getSvDebitLogAllRecords() const =0
Gets list of references to the SvDebitLogRecord read from the card.
virtual uint8_t getSoftwareVersion() const =0
Gets the Software Version field that may be set to any fixed value by the Software Issuer of the Caly...
virtual bool isDfRatified() const =0
Tells if the last session with this card has been ratified or not.
virtual const std::vector< uint8_t > & getStartupInfoRawData() const =0
Gets the raw Calypso startup information.
virtual int getSvLastTNum() const =0
Gets the last SV transaction number.
virtual const std::shared_ptr< DirectoryHeader > getDirectoryHeader() const =0
Returns the metadata of the current DF.
virtual uint8_t getApplicationType() const =0
Gets the Application Type byte which determines the Calypso product type and various options.
virtual uint8_t getSoftwareRevision() const =0
Gets the Software Revision field that may be set to any fixed value by the Software Issuer of the Cal...
virtual bool isPinBlocked() const =0
Indicates if the PIN is blocked.
virtual uint8_t getSoftwareIssuer() const =0
Gets the Software Issuer byte that indicates the entity responsible for the software of the selected ...
virtual uint8_t getSessionModification() const =0
Gets the session modification byte from the startup info structure.
virtual bool isPinFeatureAvailable() const =0
Indicates whether the card has the Calypso PIN feature.
virtual bool isRatificationOnDeselectSupported() const =0
Indicates if the ratification is done on deselect (ratification command not necessary).
virtual const std::vector< std::shared_ptr< ElementaryFile > > & getFiles() const =0
Returns a reference to the set of all known Elementary Files contains inside the current DF.
std::ostream & operator<<(std::ostream &os, const CalypsoCard::ProductType &pt)