diff options
author | Neil Horman <nhorman@openssl.org> | 2023-12-07 16:56:39 -0500 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2024-01-12 10:37:41 +0100 |
commit | 3ddab87f2e69aeea82caef1b7cef64ac7066a931 (patch) | |
tree | 80b358dd07606eee6fb1cb6bb268471e70424fc4 /providers/implementations/encode_decode/encode_key2any.c | |
parent | ac36def31f2c47133cb0427692796c6562551e99 (diff) |
Fix NULL pointer deref when parsing the stable section
When parsing the stable section of a config such as this:
openssl_conf = openssl_init
[openssl_init]
stbl_section = mstbl
[mstbl]
id-tc26 = min
Can lead to a SIGSEGV, as the parsing code doesnt recognize min as a
proper section name without a trailing colon to associate it with a
value. As a result the stack of configuration values has an entry with
a null value in it, which leads to the SIGSEGV in do_tcreate when we
attempt to pass NULL to strtoul.
Fix it by skipping any entry in the config name/value list that has a
null value, prior to passing it to stroul
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/22988)
(cherry picked from commit 0981c20f8efa68bf9d68d7715280f83812c19a7e)
Diffstat (limited to 'providers/implementations/encode_decode/encode_key2any.c')
0 files changed, 0 insertions, 0 deletions