Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
virtual P6R::P6ERR P6R::p6IKeystoreInit::initialize ( P6KEYSTOREFLAGS  flags,
p6ISymmetricCrypto pEncryptKey,
P6SIGNHMAC  signAlg,
p6ICryptoKey pSignKey 
)
pure virtual

Sets up the component to run properly.

The 'pEncryptKey' ensures that only the keystore owner can access its contents. The 'pSignKey' ensures that entries in the keystore are not modified (e.g., entries deleted / added) without the owner's permission while on disk. The pSignKey is also used to sign a key and its meta-data together to ensure the association is not modified without the owner's permission. Note, that the same keys used to create the keystore must be provided for each keystore access.

Parameters
flags[ in ] Set perferences for the new object
pEncryptKey[ in ] The key encrypting key used to wrap all keys in the keystore. A fully initialized p6ISymmetricCrypto component (i.e., setKey() must have been called).
signAlg[ in ] Defines the type of signature algorithm used with the pSignKey
pSignKey[ in ] A key to sign / verify the keystore wide signature (e.g., SH_SHA1) and to provide "row" level signatures
Returns
SuccessP6R::eOk 
FailureP6R::eInvalidArgOne of the parameters is NULL.
P6R::eAlreadyInitializedCan only be called once successfully.