Output length
|
Comments
|
C_Encrypt
|
RC4
|
any
|
same as input length
|
no final part
|
C_Decrypt
|
RC4
|
any
|
same as input length
|
no final part
|
For this mechanism, the ulMinKeySize and ulMaxKeySize fields of the CK_MECHANISM_INFO structure specify the supported range of RC4 key sizes, in bits.
11.14. About RC5
RC5 is a parametrizable block cipher for which RSA Data Security has patent pending. It has a variable wordsize, a variable keysize, and a variable number of rounds. The blocksize of RC5 is always equal to twice its wordsize.
CK_RC5_PARAMS; CK_RC5_PARAMS_PTR
CK_RC5_PARAMS provides the parameters to the CKM_RC5_ECB and CKM_RC5_MAC mechanisms. It is defined as follows:
typedef struct CK_RC5_PARAMS {
CK_ULONG ulWordsize;
CK_ULONG ulRounds;
} CK_RC5_PARAMS;
The fields of the structure have the following meanings:
ulWordsize wordsize of RC5 cipher in bytes
ulRounds number of rounds of RC5 encipherment
CK_RC5_PARAMS_PTR is a pointer to a CK_RC5_PARAMS.
CK_RC5_CBC_PARAMS; CK_RC5_CBC_PARAMS_PTR
CK_RC5_CBC_PARAMS is a structure that provides the parameters to the CKM_RC5_CBC and CKM_RC5_CBC_PAD mechanisms. It is defined as follows:
typedef struct CK_RC5_CBC_PARAMS {
CK_ULONG ulWordsize;
CK_ULONG ulRounds;
CK_BYTE_PTR pIv;
CK_ULONG ulIvLen;
} CK_RC5_CBC_PARAMS;
The fields of the structure have the following meanings:
ulWordsize wordsize of RC5 cipher in bytes
ulRounds number of rounds of RC5 encipherment
pIv pointer to initialization vector (IV) for CBC encryption
ulIvLen length of initialization vector (must be same as blocksize)
Share with your friends: