Update PKCS#7 enveloped data to new API.
[openssl.git] / crypto / rsa / rsa_pmeth.c
index 5f357b98c6f11d2d3295cfdfc4a658651a76d49a..01a4030f16c59508183d0f9d9be764784393cf7b 100644 (file)
@@ -1,3 +1,4 @@
+/* crypto/rsa/rsa_pmeth.c */
 /* Written by Dr Stephen N Henson (shenson@bigfoot.com) for the OpenSSL
  * project 2006.
  */
 /* Written by Dr Stephen N Henson (shenson@bigfoot.com) for the OpenSSL
  * project 2006.
  */
@@ -404,6 +405,10 @@ static int pkey_rsa_ctrl(EVP_PKEY_CTX *ctx, int type, int p1, void *p2)
                rctx->md = p2;
                return 1;
 
                rctx->md = p2;
                return 1;
 
+               case EVP_PKEY_CTRL_PKCS7_ENCRYPT:
+               case EVP_PKEY_CTRL_PKCS7_DECRYPT:
+               return 1;
+
                default:
                return -2;
 
                default:
                return -2;
 
@@ -497,7 +502,7 @@ static int pkey_rsa_keygen(EVP_PKEY_CTX *ctx, EVP_PKEY *pkey)
 const EVP_PKEY_METHOD rsa_pkey_meth = 
        {
        EVP_PKEY_RSA,
 const EVP_PKEY_METHOD rsa_pkey_meth = 
        {
        EVP_PKEY_RSA,
-       0,
+       EVP_PKEY_FLAG_AUTOARGLEN,
        pkey_rsa_init,
        pkey_rsa_cleanup,
 
        pkey_rsa_init,
        pkey_rsa_cleanup,