Generates a shared secret of the requested length by applying the ANSI X9.42/X9.63 KDF with SHA-1 to the output of a DH key agreement.
#include "huidlc.h"
int hu_IDLCDHSharedGen(sb_Params idlcParams, sb_PrivateKey privateKey, sb_PublicKey remotePublicKey, size_t addInfoLen, const unsigned char *addInfo, size_t secretLen, unsigned char *sharedSecret, sb_GlobalCtx sbCtx)
BlackBerry 10.0.0
IDLC parameters object.
IDLC private key object.
IDLC public key object.
The length (in bytes) of additional information. (Optional)
Additional information for use with the KDF. (Optional - set to NULL if not used.)
The length (in bytes) of the shared secret.
Shared secret value.
A global context.
The idlcParams object is NULL.
The tag for the params object is not of the expected type.
The private key object is NULL.
The private key object is invalid.
The public key object is NULL.
The public key object is invalid.
Additional information is NULL.
The shared secret buffer is NULL.
The length of the shared secret is invalid.
Memory allocation failure.
Success.