diff options
author | Pauli <ppzgs1@gmail.com> | 2021-02-25 04:49:10 +0100 |
---|---|---|
committer | Pauli <ppzgs1@gmail.com> | 2021-02-28 08:25:49 +0100 |
commit | 0edb81944133a5f2f9e4c6fd7282e40a2d1aa582 (patch) | |
tree | b3dd60ddaef422b384f673c325841abba24e6b79 /ssl/t1_lib.c | |
parent | evp: updates for the new additional MAC_init arguments (diff) | |
download | openssl-0edb81944133a5f2f9e4c6fd7282e40a2d1aa582.tar.xz openssl-0edb81944133a5f2f9e4c6fd7282e40a2d1aa582.zip |
tls: updates for the new additional MAC_init arguments
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/14310)
Diffstat (limited to 'ssl/t1_lib.c')
-rw-r--r-- | ssl/t1_lib.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/ssl/t1_lib.c b/ssl/t1_lib.c index ace890d915..4d66db9f9d 100644 --- a/ssl/t1_lib.c +++ b/ssl/t1_lib.c @@ -3393,13 +3393,12 @@ EVP_MAC_CTX *ssl_hmac_get0_EVP_MAC_CTX(SSL_HMAC *ctx) int ssl_hmac_init(SSL_HMAC *ctx, void *key, size_t len, char *md) { - OSSL_PARAM params[3], *p = params; + OSSL_PARAM params[2], *p = params; if (ctx->ctx != NULL) { *p++ = OSSL_PARAM_construct_utf8_string(OSSL_MAC_PARAM_DIGEST, md, 0); - *p++ = OSSL_PARAM_construct_octet_string(OSSL_KDF_PARAM_KEY, key, len); *p = OSSL_PARAM_construct_end(); - if (EVP_MAC_CTX_set_params(ctx->ctx, params) && EVP_MAC_init(ctx->ctx)) + if (EVP_MAC_init(ctx->ctx, key, len, params)) return 1; } #ifndef OPENSSL_NO_DEPRECATED_3_0 |