Loading crypto/asn1/ameth_lib.c +11 −5 Original line number Diff line number Diff line Loading @@ -70,15 +70,23 @@ extern const EVP_PKEY_ASN1_METHOD eckey_asn1_meth; /* Keep this sorted in type order !! */ const EVP_PKEY_ASN1_METHOD *standard_methods[] = { #ifndef OPENSSL_NO_RSA &rsa_asn1_meths[0], &rsa_asn1_meths[1], #endif #ifndef OPENSSL_NO_DH &dh_asn1_meth, #endif #ifndef OPENSSL_NO_DSA &dsa_asn1_meths[0], &dsa_asn1_meths[1], &dsa_asn1_meths[2], &dsa_asn1_meths[3], &dsa_asn1_meths[4], #endif #ifndef OPENSSL_NO_EC &eckey_asn1_meth #endif }; typedef int sk_cmp_fn_type(const char * const *a, const char * const *b); Loading Loading @@ -209,12 +217,10 @@ EVP_PKEY_ASN1_METHOD* EVP_PKEY_asn1_new(int id, ameth->pub_cmp = 0; ameth->pub_print = 0; ameth->priv_decode = 0; ameth->priv_encode = 0; ameth->priv_print = 0; ameth->pkey_size = 0; ameth->pkey_bits = 0; Loading @@ -225,7 +231,6 @@ EVP_PKEY_ASN1_METHOD* EVP_PKEY_asn1_new(int id, ameth->param_cmp = 0; ameth->param_print = 0; ameth->pkey_free = 0; ameth->pkey_ctrl = 0; Loading Loading @@ -279,8 +284,9 @@ void EVP_PKEY_asn1_set_private(EVP_PKEY_ASN1_METHOD *ameth, } void EVP_PKEY_asn1_set_param(EVP_PKEY_ASN1_METHOD *ameth, int (*param_decode)(const EVP_PKEY *pk, X509_PUBKEY *pub), int (*param_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk), int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen), int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder), int (*param_missing)(const EVP_PKEY *pk), int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from), int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b), Loading crypto/asn1/asn1_locl.h +5 −4 Original line number Diff line number Diff line /* asn1t.h */ /* Written by Dr Stephen N Henson (shenson@bigfoot.com) for the OpenSSL * project 2005. * project 2006. */ /* ==================================================================== * Copyright (c) 2005 The OpenSSL Project. All rights reserved. * Copyright (c) 2006 The OpenSSL Project. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions Loading Loading @@ -97,8 +97,9 @@ struct evp_pkey_asn1_method_st int (*pkey_size)(const EVP_PKEY *pk); int (*pkey_bits)(const EVP_PKEY *pk); int (*param_decode)(const EVP_PKEY *pk, X509_PUBKEY *pub); int (*param_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk); int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen); int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder); int (*param_missing)(const EVP_PKEY *pk); int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from); int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b); Loading crypto/evp/evp.h +6 −2 Original line number Diff line number Diff line Loading @@ -777,6 +777,7 @@ int EVP_PKEY_type(int type); int EVP_PKEY_bits(EVP_PKEY *pkey); int EVP_PKEY_size(EVP_PKEY *pkey); int EVP_PKEY_assign(EVP_PKEY *pkey,int type,char *key); void * EVP_PKEY_get0(EVP_PKEY *pkey); #ifndef OPENSSL_NO_RSA struct rsa_st; Loading Loading @@ -868,14 +869,17 @@ void EVP_PKEY_asn1_set_private(EVP_PKEY_ASN1_METHOD *ameth, int (*priv_encode)(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pk), int (*priv_print)(BIO *out, const EVP_PKEY *pkey, int indent, ASN1_PCTX *pctx)); void EVP_PKEY_asn1_set_param(EVP_PKEY_ASN1_METHOD *ameth, int (*param_decode)(const EVP_PKEY *pk, X509_PUBKEY *pub), int (*param_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk), int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen), int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder), int (*param_missing)(const EVP_PKEY *pk), int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from), int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b), int (*param_print)(BIO *out, const EVP_PKEY *pkey, int indent, ASN1_PCTX *pctx)); void EVP_PKEY_asn1_set_free(EVP_PKEY_ASN1_METHOD *ameth, void (*pkey_free)(EVP_PKEY *pkey)); void EVP_PKEY_asn1_set_ctrl(EVP_PKEY_ASN1_METHOD *ameth, Loading crypto/evp/p_lib.c +5 −0 Original line number Diff line number Diff line Loading @@ -199,6 +199,11 @@ int EVP_PKEY_assign(EVP_PKEY *pkey, int type, char *key) return(key != NULL); } void *EVP_PKEY_get0(EVP_PKEY *pkey) { return pkey->pkey.ptr; } #ifndef OPENSSL_NO_RSA int EVP_PKEY_set1_RSA(EVP_PKEY *pkey, RSA *key) { Loading crypto/pem/pem.h +2 −0 Original line number Diff line number Diff line Loading @@ -133,6 +133,7 @@ extern "C" { #define PEM_STRING_ECDSA_PUBLIC "ECDSA PUBLIC KEY" #define PEM_STRING_ECPARAMETERS "EC PARAMETERS" #define PEM_STRING_ECPRIVATEKEY "EC PRIVATE KEY" #define PEM_STRING_PARAMETERS "PARAMETERS" /* Note that this structure is initialised by PEM_SealInit and cleaned up by PEM_SealFinal (at least for now) */ Loading Loading @@ -724,6 +725,7 @@ void ERR_load_PEM_strings(void); #define PEM_F_PEM_PK8PKEY 119 #define PEM_F_PEM_READ 108 #define PEM_F_PEM_READ_BIO 109 #define PEM_F_PEM_READ_BIO_PARAMETERS 140 #define PEM_F_PEM_READ_BIO_PRIVATEKEY 123 #define PEM_F_PEM_READ_PRIVATEKEY 124 #define PEM_F_PEM_SEALFINAL 110 Loading Loading
crypto/asn1/ameth_lib.c +11 −5 Original line number Diff line number Diff line Loading @@ -70,15 +70,23 @@ extern const EVP_PKEY_ASN1_METHOD eckey_asn1_meth; /* Keep this sorted in type order !! */ const EVP_PKEY_ASN1_METHOD *standard_methods[] = { #ifndef OPENSSL_NO_RSA &rsa_asn1_meths[0], &rsa_asn1_meths[1], #endif #ifndef OPENSSL_NO_DH &dh_asn1_meth, #endif #ifndef OPENSSL_NO_DSA &dsa_asn1_meths[0], &dsa_asn1_meths[1], &dsa_asn1_meths[2], &dsa_asn1_meths[3], &dsa_asn1_meths[4], #endif #ifndef OPENSSL_NO_EC &eckey_asn1_meth #endif }; typedef int sk_cmp_fn_type(const char * const *a, const char * const *b); Loading Loading @@ -209,12 +217,10 @@ EVP_PKEY_ASN1_METHOD* EVP_PKEY_asn1_new(int id, ameth->pub_cmp = 0; ameth->pub_print = 0; ameth->priv_decode = 0; ameth->priv_encode = 0; ameth->priv_print = 0; ameth->pkey_size = 0; ameth->pkey_bits = 0; Loading @@ -225,7 +231,6 @@ EVP_PKEY_ASN1_METHOD* EVP_PKEY_asn1_new(int id, ameth->param_cmp = 0; ameth->param_print = 0; ameth->pkey_free = 0; ameth->pkey_ctrl = 0; Loading Loading @@ -279,8 +284,9 @@ void EVP_PKEY_asn1_set_private(EVP_PKEY_ASN1_METHOD *ameth, } void EVP_PKEY_asn1_set_param(EVP_PKEY_ASN1_METHOD *ameth, int (*param_decode)(const EVP_PKEY *pk, X509_PUBKEY *pub), int (*param_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk), int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen), int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder), int (*param_missing)(const EVP_PKEY *pk), int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from), int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b), Loading
crypto/asn1/asn1_locl.h +5 −4 Original line number Diff line number Diff line /* asn1t.h */ /* Written by Dr Stephen N Henson (shenson@bigfoot.com) for the OpenSSL * project 2005. * project 2006. */ /* ==================================================================== * Copyright (c) 2005 The OpenSSL Project. All rights reserved. * Copyright (c) 2006 The OpenSSL Project. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions Loading Loading @@ -97,8 +97,9 @@ struct evp_pkey_asn1_method_st int (*pkey_size)(const EVP_PKEY *pk); int (*pkey_bits)(const EVP_PKEY *pk); int (*param_decode)(const EVP_PKEY *pk, X509_PUBKEY *pub); int (*param_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk); int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen); int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder); int (*param_missing)(const EVP_PKEY *pk); int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from); int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b); Loading
crypto/evp/evp.h +6 −2 Original line number Diff line number Diff line Loading @@ -777,6 +777,7 @@ int EVP_PKEY_type(int type); int EVP_PKEY_bits(EVP_PKEY *pkey); int EVP_PKEY_size(EVP_PKEY *pkey); int EVP_PKEY_assign(EVP_PKEY *pkey,int type,char *key); void * EVP_PKEY_get0(EVP_PKEY *pkey); #ifndef OPENSSL_NO_RSA struct rsa_st; Loading Loading @@ -868,14 +869,17 @@ void EVP_PKEY_asn1_set_private(EVP_PKEY_ASN1_METHOD *ameth, int (*priv_encode)(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pk), int (*priv_print)(BIO *out, const EVP_PKEY *pkey, int indent, ASN1_PCTX *pctx)); void EVP_PKEY_asn1_set_param(EVP_PKEY_ASN1_METHOD *ameth, int (*param_decode)(const EVP_PKEY *pk, X509_PUBKEY *pub), int (*param_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk), int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen), int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder), int (*param_missing)(const EVP_PKEY *pk), int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from), int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b), int (*param_print)(BIO *out, const EVP_PKEY *pkey, int indent, ASN1_PCTX *pctx)); void EVP_PKEY_asn1_set_free(EVP_PKEY_ASN1_METHOD *ameth, void (*pkey_free)(EVP_PKEY *pkey)); void EVP_PKEY_asn1_set_ctrl(EVP_PKEY_ASN1_METHOD *ameth, Loading
crypto/evp/p_lib.c +5 −0 Original line number Diff line number Diff line Loading @@ -199,6 +199,11 @@ int EVP_PKEY_assign(EVP_PKEY *pkey, int type, char *key) return(key != NULL); } void *EVP_PKEY_get0(EVP_PKEY *pkey) { return pkey->pkey.ptr; } #ifndef OPENSSL_NO_RSA int EVP_PKEY_set1_RSA(EVP_PKEY *pkey, RSA *key) { Loading
crypto/pem/pem.h +2 −0 Original line number Diff line number Diff line Loading @@ -133,6 +133,7 @@ extern "C" { #define PEM_STRING_ECDSA_PUBLIC "ECDSA PUBLIC KEY" #define PEM_STRING_ECPARAMETERS "EC PARAMETERS" #define PEM_STRING_ECPRIVATEKEY "EC PRIVATE KEY" #define PEM_STRING_PARAMETERS "PARAMETERS" /* Note that this structure is initialised by PEM_SealInit and cleaned up by PEM_SealFinal (at least for now) */ Loading Loading @@ -724,6 +725,7 @@ void ERR_load_PEM_strings(void); #define PEM_F_PEM_PK8PKEY 119 #define PEM_F_PEM_READ 108 #define PEM_F_PEM_READ_BIO 109 #define PEM_F_PEM_READ_BIO_PARAMETERS 140 #define PEM_F_PEM_READ_BIO_PRIVATEKEY 123 #define PEM_F_PEM_READ_PRIVATEKEY 124 #define PEM_F_PEM_SEALFINAL 110 Loading