Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
virtual P6R::P6ERR P6R::p6ISymmetricCrypto2::AESUnwrapKey ( const P6UCHAR pIV,
P6UINT32  ivSize,
const P6UCHAR pInData,
P6UINT32  inSize,
P6UCHAR pOutData,
P6UINT32 pOutSize 
)
pure virtual

Use the AES key loaded into the SymmetricCrypto object (via a call to setKey()) and use it with the AES unwrap algorithm to unwrap an encrypted crypto key provided in the pInData parameter.

Parameters
pIV[ in ] Has to be 8 bytes long for the AES wrap algorithm
ivSize[ in ] Size in bytes of the IV provided in pIV
pInData[ in ] The bytes of an encrypted key to be unwrapped by the AES key contained in the SymmetricCrypto object
inSize[ in ] Size in bytes of the data in pInData (must be a multiple of 8)
pOutData[ out ] Contains the original unwrapped key
pOutSize[ in ] Size in bytes of the pOutData array [ out ] Specifies the number of bytes written into pOutData.
Returns
SuccessP6R::eOk 
FailureP6R::eNotInitializedA successful call to initialize was not made before this call.
P6R::eInvalidArgOne of the parameters is NULL.
P6R::eInvalidStateLoaded key is not an AES key.
P6R::eRangeData in pInData parameter is not a multiple of 8.
P6R::eTooSmallThe pOutData buffer is too small to hold the wrapped result data.
P6R::eFailThe unwrap operation failed.F