diff --git a/src/ssl.c b/src/ssl.c index 8a8fef5f90..6d0ef95dd7 100644 --- a/src/ssl.c +++ b/src/ssl.c @@ -17239,7 +17239,7 @@ size_t wolfSSL_get_server_random(const WOLFSSL *ssl, unsigned char *out, * NOTE: currently wolfSSL_KeepHandshakeResources(WOLFSSL* ssl) must be called * before the ephemeral key is stored. * return WOLFSSL_SUCCESS on success */ -int wolfSSL_get_server_tmp_key(const WOLFSSL* ssl, WOLFSSL_EVP_PKEY** pkey) +int wolfSSL_get_peer_tmp_key(const WOLFSSL* ssl, WOLFSSL_EVP_PKEY** pkey) { WOLFSSL_EVP_PKEY* ret = NULL; diff --git a/wolfssl/openssl/ssl.h b/wolfssl/openssl/ssl.h index 694a5fd57f..b42c73643a 100644 --- a/wolfssl/openssl/ssl.h +++ b/wolfssl/openssl/ssl.h @@ -1246,7 +1246,8 @@ typedef WOLFSSL_SRTP_PROTECTION_PROFILE SRTP_PROTECTION_PROFILE; #define SSL_CTX_set_tlsext_max_fragment_length \ wolfSSL_CTX_set_tlsext_max_fragment_length #define SSL_get_server_random wolfSSL_get_server_random -#define SSL_get_server_tmp_key wolfSSL_get_server_tmp_key +#define SSL_get_server_tmp_key wolfSSL_get_peer_tmp_key +#define SSL_get_peer_tmp_key wolfSSL_get_peer_tmp_key #define SSL_CTX_set_min_proto_version wolfSSL_CTX_set_min_proto_version #define SSL_CTX_set_max_proto_version wolfSSL_CTX_set_max_proto_version diff --git a/wolfssl/ssl.h b/wolfssl/ssl.h index 1dc12e7d83..bdfac80583 100644 --- a/wolfssl/ssl.h +++ b/wolfssl/ssl.h @@ -4397,7 +4397,9 @@ WOLFSSL_API size_t wolfSSL_BIO_wpending(const WOLFSSL_BIO *bio); WOLFSSL_API int wolfSSL_BIO_supports_pending(const WOLFSSL_BIO *bio); WOLFSSL_API size_t wolfSSL_BIO_ctrl_pending(WOLFSSL_BIO *b); -WOLFSSL_API int wolfSSL_get_server_tmp_key(const WOLFSSL* ssl, WOLFSSL_EVP_PKEY** pkey); +/* Definition for backwards comaptiblity */ +#define wolfSSL_get_server_tmp_key wolfSSL_get_peer_tmp_key +WOLFSSL_API int wolfSSL_get_peer_tmp_key(const WOLFSSL* ssl, WOLFSSL_EVP_PKEY** pkey); WOLFSSL_API int wolfSSL_CTX_set_min_proto_version(WOLFSSL_CTX* ctx, int version); WOLFSSL_API int wolfSSL_CTX_set_max_proto_version(WOLFSSL_CTX* ctx, int version);