/*
- * Copyright 2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the Apache License 2.0 (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
#include <openssl/core_names.h>
#include <openssl/params.h>
#include <openssl/err.h>
+#include <openssl/proverr.h>
#include "internal/cryptlib.h"
#include "crypto/ecx.h"
#include "prov/implementations.h"
#include "prov/providercommon.h"
-#include "prov/providercommonerr.h"
#ifdef S390X_EC_ASM
# include "s390x_arch.h"
#endif
if (ecxctx == NULL
|| key == NULL
|| key->keylen != ecxctx->keylen
- || !ecx_key_up_ref(key)) {
+ || !ossl_ecx_key_up_ref(key)) {
ERR_raise(ERR_LIB_PROV, ERR_R_INTERNAL_ERROR);
return 0;
}
- ecx_key_free(ecxctx->key);
+ ossl_ecx_key_free(ecxctx->key);
ecxctx->key = key;
return 1;
if (ecxctx == NULL
|| key == NULL
|| key->keylen != ecxctx->keylen
- || !ecx_key_up_ref(key)) {
+ || !ossl_ecx_key_up_ref(key)) {
ERR_raise(ERR_LIB_PROV, ERR_R_INTERNAL_ERROR);
return 0;
}
- ecx_key_free(ecxctx->peerkey);
+ ossl_ecx_key_free(ecxctx->peerkey);
ecxctx->peerkey = key;
return 1;
{
PROV_ECX_CTX *ecxctx = (PROV_ECX_CTX *)vecxctx;
- ecx_key_free(ecxctx->key);
- ecx_key_free(ecxctx->peerkey);
+ ossl_ecx_key_free(ecxctx->key);
+ ossl_ecx_key_free(ecxctx->peerkey);
OPENSSL_free(ecxctx);
}
}
*dstctx = *srcctx;
- if (dstctx->key != NULL && !ecx_key_up_ref(dstctx->key)) {
+ if (dstctx->key != NULL && !ossl_ecx_key_up_ref(dstctx->key)) {
ERR_raise(ERR_LIB_PROV, ERR_R_INTERNAL_ERROR);
OPENSSL_free(dstctx);
return NULL;
}
- if (dstctx->peerkey != NULL && !ecx_key_up_ref(dstctx->peerkey)) {
+ if (dstctx->peerkey != NULL && !ossl_ecx_key_up_ref(dstctx->peerkey)) {
ERR_raise(ERR_LIB_PROV, ERR_R_INTERNAL_ERROR);
- ecx_key_free(dstctx->key);
+ ossl_ecx_key_free(dstctx->key);
OPENSSL_free(dstctx);
return NULL;
}