[openssl-commits] [openssl] master update

Richard Levitte levitte at openssl.org
Mon Oct 30 17:17:19 UTC 2017


The branch master has been updated
       via  5e006082199e9a0f37ba35116ff217bc643dd317 (commit)
      from  f403feea11d1ea26fd5b7d9732361cfc3f9f91a9 (commit)


- Log -----------------------------------------------------------------
commit 5e006082199e9a0f37ba35116ff217bc643dd317
Author: Richard Levitte <levitte at openssl.org>
Date:   Thu Oct 26 10:54:08 2017 +0200

    EVP_PKEY_ASN1_METHOD: add functions to set siginf_set and pkey_check methods
    
    Reviewed-by: Bernd Edlinger <bernd.edlinger at hotmail.de>
    (Merged from https://github.com/openssl/openssl/pull/4589)

-----------------------------------------------------------------------

Summary of changes:
 crypto/asn1/ameth_lib.c | 18 ++++++++++++++++++
 include/openssl/evp.h   |  8 ++++++++
 util/libcrypto.num      |  2 ++
 3 files changed, 28 insertions(+)

diff --git a/crypto/asn1/ameth_lib.c b/crypto/asn1/ameth_lib.c
index 82868e1..5f523b2 100644
--- a/crypto/asn1/ameth_lib.c
+++ b/crypto/asn1/ameth_lib.c
@@ -251,6 +251,10 @@ void EVP_PKEY_asn1_copy(EVP_PKEY_ASN1_METHOD *dst,
     dst->item_sign = src->item_sign;
     dst->item_verify = src->item_verify;
 
+    dst->siginf_set = src->siginf_set;
+
+    dst->pkey_check = src->pkey_check;
+
 }
 
 void EVP_PKEY_asn1_free(EVP_PKEY_ASN1_METHOD *ameth)
@@ -359,3 +363,17 @@ void EVP_PKEY_asn1_set_item(EVP_PKEY_ASN1_METHOD *ameth,
     ameth->item_sign = item_sign;
     ameth->item_verify = item_verify;
 }
+
+void EVP_PKEY_asn1_set_siginf(EVP_PKEY_ASN1_METHOD *ameth,
+                              int (*siginf_set) (X509_SIG_INFO *siginf,
+                                                 const X509_ALGOR *alg,
+                                                 const ASN1_STRING *sig))
+{
+    ameth->siginf_set = siginf_set;
+}
+
+void EVP_PKEY_asn1_set_check(EVP_PKEY_ASN1_METHOD *ameth,
+                             int (*pkey_check) (const EVP_PKEY *pk))
+{
+    ameth->pkey_check = pkey_check;
+}
diff --git a/include/openssl/evp.h b/include/openssl/evp.h
index 40ed8d2..90add83 100644
--- a/include/openssl/evp.h
+++ b/include/openssl/evp.h
@@ -1198,6 +1198,14 @@ void EVP_PKEY_asn1_set_item(EVP_PKEY_ASN1_METHOD *ameth,
                                               X509_ALGOR *alg2,
                                               ASN1_BIT_STRING *sig));
 
+void EVP_PKEY_asn1_set_siginf(EVP_PKEY_ASN1_METHOD *ameth,
+                              int (*siginf_set) (X509_SIG_INFO *siginf,
+                                                 const X509_ALGOR *alg,
+                                                 const ASN1_STRING *sig));
+
+void EVP_PKEY_asn1_set_check(EVP_PKEY_ASN1_METHOD *ameth,
+                             int (*pkey_check) (const EVP_PKEY *pk));
+
 void EVP_PKEY_asn1_set_security_bits(EVP_PKEY_ASN1_METHOD *ameth,
                                      int (*pkey_security_bits) (const EVP_PKEY
                                                                 *pk));
diff --git a/util/libcrypto.num b/util/libcrypto.num
index f4e3451..a9281ce 100644
--- a/util/libcrypto.num
+++ b/util/libcrypto.num
@@ -4418,3 +4418,5 @@ RAND_POOL_add_begin                     4362	1_1_1	EXIST::FUNCTION:
 RAND_POOL_add_end                       4363	1_1_1	EXIST::FUNCTION:
 RAND_POOL_acquire_entropy               4364	1_1_1	EXIST::FUNCTION:
 OPENSSL_sk_new_reserve                  4365	1_1_1	EXIST::FUNCTION:
+EVP_PKEY_asn1_set_check                 4366	1_1_1	EXIST::FUNCTION:
+EVP_PKEY_asn1_set_siginf                4367	1_1_1	EXIST::FUNCTION:


More information about the openssl-commits mailing list