Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
virtual P6R::P6ERR P6R::p6ILicense::setKeys ( p6ICryptoKey pPublicKey,
p6ICryptoKey pPrivateKey,
P6SIGNHMAC  algorithm 
)
pure virtual

This component does not do key management.

It is the calling application's responsibility to manage and provide the proper keys to this component. This method can be invoked many times to change the keys in use.

Note, that either pPublicKeyFile or pPrivateKeyFile parameters can be NULL depending on the value of the mode parameter to initialize. It is possible that a released product would not include its private key and only need its public key to verify its license file.

Parameters
pPublicKey[ in ] A pointer to a p6ICryptoKey interface containing the public key Can be NULL if mode == LICENSE_CREATE (i.e., used for calls to verifyLicenseFile).
pPrivateKey[ in ] A pointer to a private key Can be NULL if mode == LICENSE_VERIFY (i.e., used for calls to createLicenseFile).
algorithm[ in ] The type of signing algorthm to use to generate or verify the license.
Returns
SuccessP6R::eOk 
FailureP6R::eNotInitializedA successful call to initialize was not made before this call.
P6R:eInvalidArgm_mode is LICENSE_VERIFY and pPublicKeyFile is NULL, or m_mode is LICENSE_CREATE and pPrivateKeyFile is NULL.
P6R::eWrongKeyClassP6R::CKC_PRIVATE and P6R::CKC_PUBLIC keys required