Attach a symmetric key-encryption key to a KEK RecipientInfo (transfers ownership of key).
Declared in <openssl/cms.h>
int
CMS_RecipientInfo_set0_key(
CMS_RecipientInfo* ri,
unsigned char* key,
size_t keylen);
1 on success, or 0 on failure.
| Name | Description |
|---|---|
| ri | Recipient info of type CMS_RECIPINFO_KEK. |
| key | Key bytes allocated with OPENSSL_malloc(); ownership transferred to ri (may be NULL to clear). |
| keylen | Length of key in bytes. |