10 #ifndef __BRP_BALTECH_SDK_CMDS_CRYPTO_H__ 11 #define __BRP_BALTECH_SDK_CMDS_CRYPTO_H__ 12 #include "../typedefs.h" 16 #define BRP_Crypto_CrptErrInvalidBlock BRP_ERR_STATUS(0x0200, 0x01) 20 #define BRP_Crypto_CrptErrAuth BRP_ERR_STATUS(0x0200, 0x02) 24 #define BRP_Crypto_CrptErrKeyNotFound BRP_ERR_STATUS(0x0200, 0x03) 28 #define BRP_Crypto_CrptErrWriteConfigkey BRP_ERR_STATUS(0x0200, 0x04) 34 #define BRP_Crypto_CrptErrInvalidKey BRP_ERR_STATUS(0x0200, 0x05) 54 #ifdef BRP_SUPPORT_LEGACY_METHODS 78 #ifdef BRP_SUPPORT_LEGACY_METHODS 112 #ifdef BRP_SUPPORT_LEGACY_METHODS 146 #ifdef BRP_SUPPORT_LEGACY_METHODS 186 #ifdef BRP_SUPPORT_LEGACY_METHODS 187 brp_errcode brp_Crypto_BalKeyEncryptBuffer(
brp_protocol protocol,
unsigned KeyVersion,
unsigned EmbeddedKeyIndex,
unsigned EmbeddedKeyPos,
brp_buf Buffer,
size_t Buffer_len,
brp_buf InitialVector,
size_t InitialVector_len,
brp_buf* EncryptedBuffer,
size_t* EncryptedBuffer_len,
brp_buf* NextInitialVector,
size_t* NextInitialVector_len,
brp_mempool *mempool);
206 #ifdef BRP_SUPPORT_LEGACY_METHODS 226 #ifdef BRP_SUPPORT_LEGACY_METHODS
brp_errcode brp_Crypto_CopyConfigKey(brp_Crypto_CopyConfigKey_t params)
Copies the configuration card key 0x0202/0x85 (Device/Run/ConfigCardEncryptKey) to the Custom/Crypto/...
brp_errcode brp_Crypto_EncryptBuffer(brp_Crypto_EncryptBuffer_t params)
This command encrypts a variable length buffer given in the Buffer parameter using the SkipJack algor...
unsigned int brp_errcode
This type is used library-wide for passing error codes in the return value of functions.
size_t * EncryptedBuffer_len
brp_buf * NextInitialVector
struct brp_protocol_t * brp_protocol
This is a generic handle of a protocol.
brp_buf * UnencryptedBlock
struct brp_mempool_object_t * brp_mempool
mempool handle.
size_t * EncryptedBuffer_len
brp_buf * NextInitialVector
brp_errcode brp_Crypto_GetKeySig(brp_Crypto_GetKeySig_t params)
Returns a signature of the ConfigurationKey to identify the MasterCard needed for this reader...
brp_buf * NextInitialVector
size_t * UnencryptedBuffer_len
brp_buf * EncryptedBuffer
brp_buf * EncryptedBuffer
unsigned EmbeddedKeyIndex
brp_errcode brp_Crypto_DecryptBuffer(brp_Crypto_DecryptBuffer_t params)
This command decrypts a variable length buffer given in the Buffer parameter using the SkipJack algor...
size_t * NextInitialVector_len
brp_buf * UnencryptedBuffer
brp_errcode brp_Crypto_EncryptBlock(brp_Crypto_EncryptBlock_t params)
This command encrypts an 8-Byte data block given in the Block parameter using the SkipJack algorithm...
unsigned char * brp_buf
represents a pointer to a protocol data buffer.
brp_errcode brp_Crypto_BalKeyEncryptBuffer(brp_Crypto_BalKeyEncryptBuffer_t params)
This command is a special version of the brp_Crypto_EncryptBuffer() command which always uses a custo...
brp_errcode brp_Crypto_DecryptBlock(brp_Crypto_DecryptBlock_t params)
This command decrypts an 8-Byte data block given in the Block parameter using the SkipJack algorithm...