skip book previous and next navigation links
go up to top of book: HP Open Source Security for OpenVMS Volume 1:... HP Open Source Security for OpenVMS Volume 1:...
go to beginning of reference: API FunctionsAPI Functions
go to previous page: EncryptDataUpdateEncryptDataUpdate
go to next page: GenerateAlgorithmParamsGenerateAlgorithmParams
end of book navigation links


FreeKey
Library
Description
Errors
 Parameters
Return Value
See Also

NAME

FreeKey: CSSM_FreeKey, CSP_FreeKey - Clean up keys (CDSA)

SYNOPSIS  

# include <cssm.h>

API:CSSM_RETURN CSSMAPI CSSM_FreeKey(CSSM_CSP_HANDLE CSPHandle,const CSSM_ACCESS_CREDENTIALS *AccessCred,CSSM_KEY_PTR KeyPtr,CSSM_BOOL Delete)SPI:CSSM_RETURN CSSMCSPI CSP_FreeKey(CSSM_CSP_HANDLE CSPHandle,const CSSM_ACCESS_CREDENTIALS *AccessCred,CSSM_KEY_PTR KeyPtr,CSSM_BOOL Delete)


return to top LIBRARY  

Common Security Services Manager library (cdsa$incssm300_shr.exe)


return to top PARAMETERS  

CSPHandle (input)
 The handle that describes the module to performthis operation.
AccessCred (input/optional)
 If the target key referenced by KeyPtr isprotected and Delete has the value CSSM_TRUE, thisparameter must contain the certificates and samples required toaccess the target key. The certificates must be presented as immediatevalues in the input structure. The samples can be immediate values,be obtained through a protected mechanism, or be obtained througha callback function.
KeyPtr (input)
 The key whose associated keying material can bediscarded at this time.
Delete (input)
 If this value is CSSM_TRUE, the key data in thekey structure will be removed and any internal storage related tothat key will also be removed. In this case the key no longer existsin any form, unless previously wrapped out of the CSP by the application.If this value is CSSM_FALSE, then only the resources related tothe key structure are released. The key may still be accessibleby other means internally to the CSP.


return to top DESCRIPTION  

This function requests the Cryptographic Service Providerto clean up any key material associated with the key, and to possiblydelete the key from the CSP completely. This function also releasesthe internal storage referenced by the KeyData field of the keystructure, which can hold the actual key value. The key reference by KeyPtr canbe a persistent key or a transient key. This function clears thecached copy of the key and can have an effect on the long term persistenceor transience of the key.


return to top RETURN VALUE  

A CSSM_RETURN value indicating success or specifying a particularerror condition. The value CSSM_OK indicates success. All othervalues represent an error condition.


return to top ERRORS  

Errors are described in the CDSA Technical Standard.

None specific to this call.


return to top SEE ALSO  

Books

Intel CDSA Application Developer's Guide


go to previous page: EncryptDataUpdateEncryptDataUpdate
go to next page: GenerateAlgorithmParamsGenerateAlgorithmParams