diff options
Diffstat (limited to 'crypto/cms/cms_lib.c')
| -rw-r--r-- | crypto/cms/cms_lib.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/crypto/cms/cms_lib.c b/crypto/cms/cms_lib.c index 0738da3da280..1d2c5bc42288 100644 --- a/crypto/cms/cms_lib.c +++ b/crypto/cms/cms_lib.c @@ -76,6 +76,10 @@ CMS_ContentInfo *CMS_ContentInfo_new(void) void CMS_ContentInfo_free(CMS_ContentInfo *cms) { if (cms != NULL) { + CMS_EncryptedContentInfo *ec = ossl_cms_get0_env_enc_content(cms); + + if (ec != NULL) + OPENSSL_clear_free(ec->key, ec->keylen); OPENSSL_free(cms->ctx.propq); ASN1_item_free((ASN1_VALUE *)cms, ASN1_ITEM_rptr(CMS_ContentInfo)); } |
