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: MDSUTIL_TermMDSUTIL_Term
go to next page: PassThroughPassThrough
end of book navigation links


ObtainPrivateKeyFromPublicKey
Library
Description
Return Value
See Also
 Parameters
Notes
Errors

NAME

ObtainPrivateKeyFromPublicKey: CSSM_CSP_ObtainPrivateKeyFromPublicKey, CSP_ObtainPrivateKeyFromPublicKey - Convert public key to private key (CDSA)

SYNOPSIS  

# include <cssm.h>

API:CSSM_RETURN CSSMAPI CSSM_CSP_ObtainPrivateKeyFromPublicKey(CSSM_CSP_HANDLE CSPHandleconst CSSM_KEY *PublicKey,CSSM_KEY_PTR PrivateKey)SPI:CSSM_RETURN CSSMCSPI CSP_ObtainPrivateKeyFromPublicKey(CSSM_CSP_HANDLE CSPHandle,const CSSM_KEY *PublicKey,CSSM_KEY_PTR PrivateKey)


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.
PublicKey (input)
 The public key corresponding to the private keybeing sought.
PrivateKey (output)
 A reference to the private key corresponding tothe public key.


return to top DESCRIPTION  

Given a public key this function returns a reference to theprivate key. The private key and its associated passphrase can beused as an input to any function requiring a private key value.


return to top NOTES  

The KeyData field of the CSSM_KEY structureis allocated by the CSP. The application is required to free this memoryusing the CSSM_FreeKey() (CSSM API), or CSP_FreeKey() (CSP SPI), function or with the memory functions registeredfor the CSPHandle.


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.
CSSMERR_CSP_PRIVATE_KEY_NOT_FOUND


return to top SEE ALSO  

Books

Intel CDSA Application Developer's Guide


go to previous page: MDSUTIL_TermMDSUTIL_Term
go to next page: PassThroughPassThrough