Update - OpenSSL 1.1.1-pre7-dev
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Generated by util/mkerr.pl DO NOT EDIT
|
||||
* Copyright 1995-2017 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright 1995-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the OpenSSL license (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
@@ -66,11 +66,14 @@ static const ERR_STRING_DATA ENGINE_str_functs[] = {
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_ENGINE_UNLOCKED_FINISH, 0),
|
||||
"engine_unlocked_finish"},
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_ENGINE_UP_REF, 0), "ENGINE_up_ref"},
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_INT_CLEANUP_ITEM, 0),
|
||||
"int_cleanup_item"},
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_INT_CTRL_HELPER, 0), "int_ctrl_helper"},
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_INT_ENGINE_CONFIGURE, 0),
|
||||
"int_engine_configure"},
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_INT_ENGINE_MODULE_INIT, 0),
|
||||
"int_engine_module_init"},
|
||||
{ERR_PACK(ERR_LIB_ENGINE, ENGINE_F_OSSL_HMAC_INIT, 0), "ossl_hmac_init"},
|
||||
{0, NULL}
|
||||
};
|
||||
|
||||
|
||||
+12
-5
@@ -20,7 +20,8 @@ CRYPTO_ONCE engine_lock_init = CRYPTO_ONCE_STATIC_INIT;
|
||||
|
||||
DEFINE_RUN_ONCE(do_engine_lock_init)
|
||||
{
|
||||
OPENSSL_init_crypto(0, NULL);
|
||||
if (!OPENSSL_init_crypto(0, NULL))
|
||||
return 0;
|
||||
global_engine_lock = CRYPTO_THREAD_lock_new();
|
||||
return global_engine_lock != NULL;
|
||||
}
|
||||
@@ -126,9 +127,12 @@ static int int_cleanup_check(int create)
|
||||
|
||||
static ENGINE_CLEANUP_ITEM *int_cleanup_item(ENGINE_CLEANUP_CB *cb)
|
||||
{
|
||||
ENGINE_CLEANUP_ITEM *item = OPENSSL_malloc(sizeof(*item));
|
||||
if (item == NULL)
|
||||
ENGINE_CLEANUP_ITEM *item;
|
||||
|
||||
if ((item = OPENSSL_malloc(sizeof(*item))) == NULL) {
|
||||
ENGINEerr(ENGINE_F_INT_CLEANUP_ITEM, ERR_R_MALLOC_FAILURE);
|
||||
return NULL;
|
||||
}
|
||||
item->cb = cb;
|
||||
return item;
|
||||
}
|
||||
@@ -136,6 +140,7 @@ static ENGINE_CLEANUP_ITEM *int_cleanup_item(ENGINE_CLEANUP_CB *cb)
|
||||
void engine_cleanup_add_first(ENGINE_CLEANUP_CB *cb)
|
||||
{
|
||||
ENGINE_CLEANUP_ITEM *item;
|
||||
|
||||
if (!int_cleanup_check(1))
|
||||
return;
|
||||
item = int_cleanup_item(cb);
|
||||
@@ -149,8 +154,10 @@ void engine_cleanup_add_last(ENGINE_CLEANUP_CB *cb)
|
||||
if (!int_cleanup_check(1))
|
||||
return;
|
||||
item = int_cleanup_item(cb);
|
||||
if (item)
|
||||
sk_ENGINE_CLEANUP_ITEM_push(cleanup_stack, item);
|
||||
if (item != NULL) {
|
||||
if (sk_ENGINE_CLEANUP_ITEM_push(cleanup_stack, item) <= 0)
|
||||
OPENSSL_free(item);
|
||||
}
|
||||
}
|
||||
|
||||
/* The API function that performs all cleanup */
|
||||
|
||||
@@ -317,7 +317,8 @@ ENGINE *ENGINE_by_id(const char *id)
|
||||
* Prevent infinite recursion if we're looking for the dynamic engine.
|
||||
*/
|
||||
if (strcmp(id, "dynamic")) {
|
||||
if ((load_dir = getenv("OPENSSL_ENGINES")) == NULL)
|
||||
if (OPENSSL_issetugid()
|
||||
|| (load_dir = getenv("OPENSSL_ENGINES")) == NULL)
|
||||
load_dir = ENGINESDIR;
|
||||
iterator = ENGINE_by_id("dynamic");
|
||||
if (!iterator || !ENGINE_ctrl_cmd_string(iterator, "ID", id, 0) ||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2001-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright 2001-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
|
||||
*
|
||||
* Licensed under the OpenSSL license (the "License"). You may not use
|
||||
@@ -431,9 +431,10 @@ static int ossl_hmac_init(EVP_PKEY_CTX *ctx)
|
||||
{
|
||||
OSSL_HMAC_PKEY_CTX *hctx;
|
||||
|
||||
hctx = OPENSSL_zalloc(sizeof(*hctx));
|
||||
if (hctx == NULL)
|
||||
if ((hctx = OPENSSL_zalloc(sizeof(*hctx))) == NULL) {
|
||||
ENGINEerr(ENGINE_F_OSSL_HMAC_INIT, ERR_R_MALLOC_FAILURE);
|
||||
return 0;
|
||||
}
|
||||
hctx->ktmp.type = V_ASN1_OCTET_STRING;
|
||||
hctx->ctx = HMAC_CTX_new();
|
||||
if (hctx->ctx == NULL) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2001-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright 2001-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the OpenSSL license (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
|
||||
@@ -34,7 +34,7 @@ int ENGINE_register_ciphers(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_ciphers()
|
||||
void ENGINE_register_all_ciphers(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ int ENGINE_register_DH(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_DH()
|
||||
void ENGINE_register_all_DH(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ int ENGINE_register_digests(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_digests()
|
||||
void ENGINE_register_all_digests(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ int ENGINE_register_DSA(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_DSA()
|
||||
void ENGINE_register_all_DSA(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ int ENGINE_register_EC(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_EC()
|
||||
void ENGINE_register_all_EC(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@ int ENGINE_register_pkey_meths(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_pkey_meths()
|
||||
void ENGINE_register_all_pkey_meths(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ int ENGINE_register_RAND(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_RAND()
|
||||
void ENGINE_register_all_RAND(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ int ENGINE_register_RSA(ENGINE *e)
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ENGINE_register_all_RSA()
|
||||
void ENGINE_register_all_RSA(void)
|
||||
{
|
||||
ENGINE *e;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user