Cryptographic Token Interface Standard |
PKCS#11 |
typedef CK_ULONG CK_RSA_PKCS_MGF_TYPE;
The following MGFs are defined in PKCS #1 v2.0. The following table lists the defined functions.
Table 57, PKCS #1 RSA: Message Generation Functions
Source Identifier | Value |
CKG_MGF1_SHA1 | 0x00000001 |
CK_RSA_PKCS_MGF_TYPE_PTR is a pointer to a CK_RSA_PKCS_MGF_TYPE.
typedef CK_ULONG CK_RSA_PKCS_OAEP_SOURCE_TYPE;
The following encoding parameter sources are defined in PKCS #1 v2.0. The following table lists the defined sources along with the corresponding data type for the pSourceData field in the CK_RSA_PKCS_OAEP_PARAMS structure defined below.
Table 58, PKCS #1 RSA OAEP: Encoding parameter sources
Source Identifier | Value | Data Type |
CKZ_DATA_SPECIFIED | 0x00000001 | Array of CK_BYTE containing the value of the encoding parameter. If the parameter is empty, pSourceData must be NULL and ulSourceDataLen must be zero. |
CK_RSA_PKCS_OAEP_SOURCE_TYPE_PTR is a pointer to a CK_RSA_PKCS_OAEP_SOURCE_TYPE.
typedef struct CK_RSA_PKCS_OAEP_PARAMS { CK_MECHANISM_TYPE hashAlg; CK_RSA_PKCS_OAEP_MGF_TYPE mgf; CK_RSA_PKCS_OAEP_SOURCE_TYPE source; CK_VOID_PTR pSourceData; CK_ULONG ulSourceDataLen; } CK_RSA_PKCS_OAEP_PARAMS;
hashAlg | mechanism ID of the message digest algorithm used to calculate the digest of the encoding parameter |
mgf | mask generation function to use on the encoded block |
source | source of the encoding parameter |
pSourceData | data used as the input for the encoding parameter source |
ulSourceDataLen | length of the encoding parameter source input |
CK_RSA_PKCS_OAEP_PARAMS_PTR is a pointer to a CK_RSA_PKCS_OAEP_PARAMS.