]> git.ipfire.org Git - thirdparty/openssl.git/commit
Check appropriate OSSL_PARAM_get_* functions for NULL
authorNeil Horman <nhorman@openssl.org>
Mon, 18 Dec 2023 15:55:25 +0000 (10:55 -0500)
committerTomas Mraz <tomas@openssl.org>
Tue, 9 Jan 2024 15:56:55 +0000 (16:56 +0100)
commit806bbafe2df5b699feac6ef26e50c14e701950cf
tree6edb7a1aad81303fe7dd1c12671eb6aa56a7a3ad
parent858c7bc210a406cc7f891ac2aed78692d2e02937
Check appropriate OSSL_PARAM_get_* functions for NULL

The base type OSSL_PARAM getters will NULL deref if they are initalized
as null.  Add NULL checks for those parameters that have no expectation
of returning null (int32/64/uint32/64/BN).  Other types can be left as
allowing NULL, as a NULL setting may be meaningful (string, utf8str,
octet string, etc).

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23083)
crypto/params.c
test/params_api_test.c