summaryrefslogtreecommitdiffstats
path: root/ssl/statem/extensions.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2020-08-11 12:50:04 +0200
committerPauli <paul.dale@oracle.com>2020-08-29 09:40:10 +0200
commit6f0bd6ca1c675503962e4580e54ceecd078a8331 (patch)
treefe64ff3296d1e2dc4d2a57f375b663dbc097b633 /ssl/statem/extensions.c
parentFix some EVP_MD_CTX_* functions (diff)
downloadopenssl-6f0bd6ca1c675503962e4580e54ceecd078a8331.tar.xz
openssl-6f0bd6ca1c675503962e4580e54ceecd078a8331.zip
Ensure libssl creates libctx aware MAC keys
Convert various mac key creation function calls to use the _with_libctx variants. Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/12637)
Diffstat (limited to 'ssl/statem/extensions.c')
-rw-r--r--ssl/statem/extensions.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/ssl/statem/extensions.c b/ssl/statem/extensions.c
index 1a8e3cf829..c842e20fbf 100644
--- a/ssl/statem/extensions.c
+++ b/ssl/statem/extensions.c
@@ -1598,8 +1598,10 @@ int tls_psk_do_binder(SSL *s, const EVP_MD *md, const unsigned char *msgstart,
goto err;
}
- mackey = EVP_PKEY_new_raw_private_key(EVP_PKEY_HMAC, NULL, finishedkey,
- hashsize);
+ mackey = EVP_PKEY_new_raw_private_key_with_libctx(s->ctx->libctx, "HMAC",
+ s->ctx->propq,
+ finishedkey,
+ hashsize);
if (mackey == NULL) {
SSLfatal(s, SSL_AD_INTERNAL_ERROR, SSL_F_TLS_PSK_DO_BINDER,
ERR_R_INTERNAL_ERROR);