aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/cms/cms_asn1.c
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2013-06-19 18:17:14 +0100
committerDr. Stephen Henson <steve@openssl.org>2013-06-21 21:33:00 +0100
commite365352d6a6368039392fed14a328f8c0bf955c3 (patch)
treeaf89ba59ce03204b352c2df246fb07b800bea9e4 /crypto/cms/cms_asn1.c
parent211a14f6279f127f7a5a59948819bd939131b0b6 (diff)
downloadopenssl-e365352d6a6368039392fed14a328f8c0bf955c3.tar.gz
CMS public key parameter support.
Add support for customisation of CMS handling of signed and enveloped data from custom public key parameters. This will provide support for RSA-PSS and RSA-OAEP but could also be applied to other algorithms.
Diffstat (limited to 'crypto/cms/cms_asn1.c')
-rw-r--r--crypto/cms/cms_asn1.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/crypto/cms/cms_asn1.c b/crypto/cms/cms_asn1.c
index cfe67fb6c1..6a692cdb1d 100644
--- a/crypto/cms/cms_asn1.c
+++ b/crypto/cms/cms_asn1.c
@@ -97,6 +97,8 @@ static int cms_si_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
EVP_PKEY_free(si->pkey);
if (si->signer)
X509_free(si->signer);
+ if (si->pctx)
+ EVP_MD_CTX_cleanup(&si->mctx);
}
return 1;
}
@@ -227,6 +229,8 @@ static int cms_ri_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
EVP_PKEY_free(ktri->pkey);
if (ktri->recip)
X509_free(ktri->recip);
+ if (ktri->pctx)
+ EVP_PKEY_CTX_free(ktri->pctx);
}
else if (ri->type == CMS_RECIPINFO_KEK)
{