LibLogicalAccess  2.5.0
An Open Source RFID Library
Loading...
Searching...
No Matches
Public Member Functions | Static Public Attributes | Protected Attributes | List of all members
logicalaccess::StorageCardService Class Referenceabstract

The base storage card service class for all storage services. More...

#include <storagecardservice.hpp>

Inheritance diagram for logicalaccess::StorageCardService:
logicalaccess::CardService logicalaccess::DESFireStorageCardService logicalaccess::FeliCaStorageCardService logicalaccess::ISO15693StorageCardService logicalaccess::ISO7816StorageCardService logicalaccess::MifareStorageCardService logicalaccess::MifareUltralightStorageCardService logicalaccess::TopazStorageCardService logicalaccess::CPS3StorageCardService logicalaccess::TwicStorageCardService logicalaccess::MifarePlusSL1StorageCardService logicalaccess::MifareUltralightCStorageCardService

Public Member Functions

 StorageCardService (std::shared_ptr< Chip > chip)
 Constructor.
 
virtual ~StorageCardService ()
 
virtual void erase (std::shared_ptr< Location > location, std::shared_ptr< AccessInfo > aiToUse)=0
 Erase a specific location on the card.
 
virtual void writeData (std::shared_ptr< Location > location, std::shared_ptr< AccessInfo > aiToUse, std::shared_ptr< AccessInfo > aiToWrite, const ByteVector &data, CardBehavior behaviorFlags)=0
 Write data on a specific location, using given keys.
 
virtual ByteVector readData (std::shared_ptr< Location > location, std::shared_ptr< AccessInfo > aiToUse, size_t length, CardBehavior behaviorFlags)=0
 Read data on a specific location, using given keys.
 
virtual ByteVector readDataHeader (std::shared_ptr< Location > location, std::shared_ptr< AccessInfo > aiToUse)=0
 Read data header on a specific location, using given keys.
 
SignatureResult IKS_getLastReadSignature ()
 
- Public Member Functions inherited from logicalaccess::CardService
virtual ~CardService ()=default
 
 CardService (std::shared_ptr< Chip > chip, CardServiceType serviceType)
 Constructor.
 
virtual std::string getCSType ()=0
 
std::shared_ptr< ChipgetChip () const
 
virtual CardServiceType getServiceType () const
 Get the card service type.
 

Static Public Attributes

static constexpr const CardServiceType service_type_ = CST_STORAGE
 

Protected Attributes

SignatureResult last_read_signature_
 
- Protected Attributes inherited from logicalaccess::CardService
std::shared_ptr< Chipd_chip
 Chip object.
 
CardServiceType d_serviceType
 Card service type.
 

Detailed Description

The base storage card service class for all storage services.

Constructor & Destructor Documentation

◆ StorageCardService()

logicalaccess::StorageCardService::StorageCardService ( std::shared_ptr< Chip chip)
explicit

Constructor.

Parameters
chipThe associated chip.

◆ ~StorageCardService()

logicalaccess::StorageCardService::~StorageCardService ( )
virtual

Member Function Documentation

◆ erase()

virtual void logicalaccess::StorageCardService::erase ( std::shared_ptr< Location location,
std::shared_ptr< AccessInfo aiToUse 
)
pure virtual

◆ IKS_getLastReadSignature()

SignatureResult logicalaccess::StorageCardService::IKS_getLastReadSignature ( )
inline

Retrieve the signature for the data that were read last. This is an IKS specific feature.

◆ readData()

virtual ByteVector logicalaccess::StorageCardService::readData ( std::shared_ptr< Location location,
std::shared_ptr< AccessInfo aiToUse,
size_t  length,
CardBehavior  behaviorFlags 
)
pure virtual

◆ readDataHeader()

virtual ByteVector logicalaccess::StorageCardService::readDataHeader ( std::shared_ptr< Location location,
std::shared_ptr< AccessInfo aiToUse 
)
pure virtual

Read data header on a specific location, using given keys.

Parameters
locationThe data location.
aiToUseThe key's informations to use.
dataWill contain data after reading.
dataLengthData's length to read.
Returns
Data header length.

Implemented in logicalaccess::DESFireStorageCardService, logicalaccess::FeliCaStorageCardService, logicalaccess::ISO15693StorageCardService, logicalaccess::ISO7816StorageCardService, logicalaccess::MifareStorageCardService, logicalaccess::MifarePlusSL1StorageCardService, logicalaccess::MifareUltralightStorageCardService, and logicalaccess::TopazStorageCardService.

◆ writeData()

virtual void logicalaccess::StorageCardService::writeData ( std::shared_ptr< Location location,
std::shared_ptr< AccessInfo aiToUse,
std::shared_ptr< AccessInfo aiToWrite,
const ByteVector data,
CardBehavior  behaviorFlags 
)
pure virtual

Write data on a specific location, using given keys.

Parameters
locationThe data location.
aiToUseThe key's informations to use for write access.
aiToWriteThe key's informations to change.
dataData to write.
behaviorFlagsFlags which determines the behavior.

Implemented in logicalaccess::DESFireStorageCardService, logicalaccess::FeliCaStorageCardService, logicalaccess::ISO15693StorageCardService, logicalaccess::ISO7816StorageCardService, logicalaccess::MifareStorageCardService, logicalaccess::MifarePlusSL1StorageCardService, logicalaccess::MifareUltralightCStorageCardService, logicalaccess::MifareUltralightStorageCardService, and logicalaccess::TopazStorageCardService.

Member Data Documentation

◆ last_read_signature_

SignatureResult logicalaccess::StorageCardService::last_read_signature_
protected

◆ service_type_

constexpr const CardServiceType logicalaccess::StorageCardService::service_type_ = CST_STORAGE
staticconstexpr

The documentation for this class was generated from the following files: