CSSM_CL_CertImport
CSSM_DATA_PTR CSSMAPI CSSM_CL_CertImport
(CSSM_CL_HANDLE CLHandle,
CSSM_CERT_TYPE ForeignCertType,
CSSM_CERT_ENCODING ForeignCertEncoding,
const CSSM_DATA_PTR ForeignCert)
This function imports a certificate from the specified foreign format into the native format of the specified certificate library. The set of ForeignCertTypes supported for import is at the discretion of the certificate library and documented for each module as part of the CSSM_CLSUBSERVICE structure available from the CSSM Registry.
- CLHandle (input)
The handle that describes the add-in certificate library module used to perform this function.
- ForeignCertType (input)
A unique value that identifies the type of the certificate being imported.
- ForeignCertEncoding (input)
A unique value that identifies the encoding of the certificate being imported.
- ForeignCert (input)
A pointer to the CSSM_DATA structure containing the certificate to be imported into the certificate library modules native certificate type.
A pointer to the CSSM_DATA structure containing the native-type certificate imported from the foreign certificate. If the pointer is NULL, an error has occurred. Use CSSM_GetError to obtain the error code.
- CSSM_CL_INVALID_CL_HANDLE
Invalid Certificate Library handle.
- CSSM_CL_INVALID_DATA_POINTER
Invalid pointer input.
- CSSM_CL_UNKNOWN_FORMAT
Unrecognized certificate format.
- CSSM_CL_MEMORY_ERROR
Not enough memory.
- CSSM_CL_UNSUPPORTED_OPERATION
Add-in does not support this function.
- CSSM_CL_CERT_IMPORT_FAIL
Unable to import certificate.
CSSM_CL_CertExport
Contents | Next section | Index |