diff options
author | Shane Lontis <shane.lontis@oracle.com> | 2021-02-18 20:27:26 +1000 |
---|---|---|
committer | Shane Lontis <shane.lontis@oracle.com> | 2021-02-26 10:53:01 +1000 |
commit | 32ab57cbb4877ce7e6b4eb3f9b3cfbb0ff7cd10b (patch) | |
tree | 91e75951efa936b26e3a636b9a0daf90d60182b0 /providers/implementations/encode_decode | |
parent | 5af02212a5331cc30389246bb94f97fbcdebc23a (diff) |
Fix external symbols related to ec & sm2 keys
Partial fix for #12964
This adds ossl_ names for the following symbols:
ec_*, ecx_*, ecdh_*, ecdsa_*, sm2_*
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14231)
Diffstat (limited to 'providers/implementations/encode_decode')
-rw-r--r-- | providers/implementations/encode_decode/decode_der2key.c | 20 | ||||
-rw-r--r-- | providers/implementations/encode_decode/encode_key2text.c | 4 |
2 files changed, 12 insertions, 12 deletions
diff --git a/providers/implementations/encode_decode/decode_der2key.c b/providers/implementations/encode_decode/decode_der2key.c index 5073e660cd..fed30bf952 100644 --- a/providers/implementations/encode_decode/decode_der2key.c +++ b/providers/implementations/encode_decode/decode_der2key.c @@ -462,7 +462,7 @@ static void dsa_adjust(void *key, struct der2key_ctx_st *ctx) static void ec_adjust(void *key, struct der2key_ctx_st *ctx) { - ec_key_set0_libctx(key, PROV_LIBCTX_OF(ctx->provctx)); + ossl_ec_key_set0_libctx(key, PROV_LIBCTX_OF(ctx->provctx)); } /* @@ -472,39 +472,39 @@ static void ec_adjust(void *key, struct der2key_ctx_st *ctx) static void ecx_key_adjust(void *key, struct der2key_ctx_st *ctx) { - ecx_key_set0_libctx(key, PROV_LIBCTX_OF(ctx->provctx)); + ossl_ecx_key_set0_libctx(key, PROV_LIBCTX_OF(ctx->provctx)); } # define ed25519_evp_type EVP_PKEY_ED25519 -# define ed25519_evp_extract (extract_key_fn *)evp_pkey_get1_ED25519 +# define ed25519_evp_extract (extract_key_fn *)ossl_evp_pkey_get1_ED25519 # define ed25519_d2i_private_key NULL # define ed25519_d2i_public_key NULL # define ed25519_d2i_key_params NULL -# define ed25519_free (free_key_fn *)ecx_key_free +# define ed25519_free (free_key_fn *)ossl_ecx_key_free # define ed25519_adjust ecx_key_adjust # define ed448_evp_type EVP_PKEY_ED448 -# define ed448_evp_extract (extract_key_fn *)evp_pkey_get1_ED448 +# define ed448_evp_extract (extract_key_fn *)ossl_evp_pkey_get1_ED448 # define ed448_d2i_private_key NULL # define ed448_d2i_public_key NULL # define ed448_d2i_key_params NULL -# define ed448_free (free_key_fn *)ecx_key_free +# define ed448_free (free_key_fn *)ossl_ecx_key_free # define ed448_adjust ecx_key_adjust # define x25519_evp_type EVP_PKEY_X25519 -# define x25519_evp_extract (extract_key_fn *)evp_pkey_get1_X25519 +# define x25519_evp_extract (extract_key_fn *)ossl_evp_pkey_get1_X25519 # define x25519_d2i_private_key NULL # define x25519_d2i_public_key NULL # define x25519_d2i_key_params NULL -# define x25519_free (free_key_fn *)ecx_key_free +# define x25519_free (free_key_fn *)ossl_ecx_key_free # define x25519_adjust ecx_key_adjust # define x448_evp_type EVP_PKEY_X448 -# define x448_evp_extract (extract_key_fn *)evp_pkey_get1_X448 +# define x448_evp_extract (extract_key_fn *)ossl_evp_pkey_get1_X448 # define x448_d2i_private_key NULL # define x448_d2i_public_key NULL # define x448_d2i_key_params NULL -# define x448_free (free_key_fn *)ecx_key_free +# define x448_free (free_key_fn *)ossl_ecx_key_free # define x448_adjust ecx_key_adjust # ifndef OPENSSL_NO_SM2 diff --git a/providers/implementations/encode_decode/encode_key2text.c b/providers/implementations/encode_decode/encode_key2text.c index 103a647467..2c6c5d70db 100644 --- a/providers/implementations/encode_decode/encode_key2text.c +++ b/providers/implementations/encode_decode/encode_key2text.c @@ -25,7 +25,7 @@ #include "crypto/bn.h" /* bn_get_words() */ #include "crypto/dh.h" /* ossl_dh_get0_params() */ #include "crypto/dsa.h" /* ossl_dsa_get0_params() */ -#include "crypto/ec.h" /* ec_key_get_libctx */ +#include "crypto/ec.h" /* ossl_ec_key_get_libctx */ #include "crypto/ecx.h" /* ECX_KEY, etc... */ #include "crypto/rsa.h" /* RSA_PSS_PARAMS_30, etc... */ #include "prov/bio.h" @@ -539,7 +539,7 @@ static int ec_to_text(BIO *out, const void *key, int selection) && !print_labeled_buf(out, "pub:", pub, pub_len)) goto err; if ((selection & OSSL_KEYMGMT_SELECT_DOMAIN_PARAMETERS) != 0) - ret = ec_param_to_text(out, group, ec_key_get_libctx(ec)); + ret = ec_param_to_text(out, group, ossl_ec_key_get_libctx(ec)); err: OPENSSL_clear_free(priv, priv_len); OPENSSL_free(pub); |