CSP_DigestDataClone
CSSM_CC_HANDLE CSSMSPI CSP_DigestDataClone
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE oldCCHandle,
CSSM_CC_HANDLE newCCHandle)
This function clones a given staged message digest context with its cryptographic attributes and intermediate result.
- CSPHandle (input)
The handle that describes the add-in cryptographic service provider module used to perform up-calls to CSSM for the memory functions managed by CSSM.
- oldCCHandle (input)
The old handle that describes the context of a staged message digest operation.
- newCCHandle (output)
The new handle that describes the cloned context of a staged message digest operation.
The pointer to a user-allocated CSSM_CC_HANDLE for holding the cloned context handle return from CSSM. If the pointer is NULL, an error has occurred; use CSSM_GetError to obtain the error code.
- CSSM_CSP_INVALID_CSP_HANDLE
Invalid CSP handle.
- CSSM_CSP_INVALID_CONTEXT_HANDLE
Invalid context handle.
- CSSM_CSP_MEMORY_ERROR
Not enough memory to allocate.
- CSSM_CSP_STAGED_OPERATION_UNSUPPORTED
Staged operation unsupported.
- CSSM_CSP_STAGED_OPERATION_FAILED
Staged Cryptographic operation failed.
- CSSM_CSP_GET_STAGED_INFO_ERROR
Cannot find or get the staged information.
Comments
When a digest context is cloned, a new context is created with data associated with the parent context. Changes made to the parent context after calling this function will not be reflected in the cloned context. The cloned context could be used with the CSP_DigestDataUpdate and CSP_DigestDataFinal functions.
CSP_DigestData, CSP_DigestDataInit, CSP_DigestDataUpdate, CSP_DigestDataFinal
Contents | Next section | Index |