Fix possible null pointer dereference.

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
(Merged from https://github.com/openssl/openssl/pull/29537)
This commit is contained in:
Frederik Wedel-Heinen
2026-01-02 18:36:39 +01:00
committed by Neil Horman
parent cf8b11c184
commit 4185261efc

View File

@@ -3227,6 +3227,11 @@ int tls_provider_init(const OSSL_CORE_HANDLE *handle,
}
}
if (c_obj_create == NULL || c_obj_add_sigid == NULL) {
ERR_raise(ERR_LIB_USER, XORPROV_R_OBJ_CREATE_ERR);
goto err;
}
/*
* Register algorithms manually as add_provider_sigalgs is
* only called during session establishment -- too late for