summaryrefslogtreecommitdiffstats
path: root/crypto/crmf
diff options
context:
space:
mode:
authorPauli <paul.dale@oracle.com>2020-06-09 08:53:05 +1000
committerPauli <paul.dale@oracle.com>2020-06-11 11:16:37 +1000
commitd9c2fd51e2e278bc3f7793a104ff7b4879f6d63a (patch)
tree222cd0cb2c3f7ef9d0e61c5b5d50ecfd3be5ba31 /crypto/crmf
parent765d04c9460a304c8119f57941341a149498b9db (diff)
The EVP_MAC functions have been renamed for consistency. The EVP_MAC_CTX_*
functions are now EVP_MAC functions, usually with ctx in their names. Before 3.0 is released, the names are mutable and this prevents more inconsistencies being introduced. There are no functional or code changes. Just the renaming and a little reformatting. Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/11997)
Diffstat (limited to 'crypto/crmf')
-rw-r--r--crypto/crmf/crmf_pbm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/crmf/crmf_pbm.c b/crypto/crmf/crmf_pbm.c
index f674eeeff7..a087bc4423 100644
--- a/crypto/crmf/crmf_pbm.c
+++ b/crypto/crmf/crmf_pbm.c
@@ -202,8 +202,8 @@ int OSSL_CRMF_pbm_new(const OSSL_CRMF_PBMPARAMETER *pbmp,
macparams[1] = OSSL_PARAM_construct_octet_string(OSSL_MAC_PARAM_KEY,
basekey, bklen);
if ((mac = EVP_MAC_fetch(NULL, "HMAC", NULL)) == NULL
- || (mctx = EVP_MAC_CTX_new(mac)) == NULL
- || !EVP_MAC_CTX_set_params(mctx, macparams)
+ || (mctx = EVP_MAC_new_ctx(mac)) == NULL
+ || !EVP_MAC_set_ctx_params(mctx, macparams)
|| !EVP_MAC_init(mctx)
|| !EVP_MAC_update(mctx, msg, msglen)
|| !EVP_MAC_final(mctx, mac_res, outlen, EVP_MAX_MD_SIZE))
@@ -214,7 +214,7 @@ int OSSL_CRMF_pbm_new(const OSSL_CRMF_PBMPARAMETER *pbmp,
err:
/* cleanup */
OPENSSL_cleanse(basekey, bklen);
- EVP_MAC_CTX_free(mctx);
+ EVP_MAC_free_ctx(mctx);
EVP_MAC_free(mac);
EVP_MD_CTX_free(ctx);