]> git.ipfire.org Git - thirdparty/openssl.git/commit
Fix coverity-1604666
authorNeil Horman <nhorman@openssl.org>
Mon, 15 Jul 2024 18:30:16 +0000 (14:30 -0400)
committerTomas Mraz <tomas@openssl.org>
Wed, 17 Jul 2024 14:30:55 +0000 (16:30 +0200)
commit22e08c7cdc596d4f16749811d1022fb8b07a8e41
treedc56e7611bbb350c423d9ff5accdae39f2800ffb
parenta753547eefc9739f341824a0cb0642afe7a06fcc
Fix coverity-1604666

Coverity recently flaged an error in which the return value for
EVP_MD_get_size wasn't checked for negative values prior to use, which
can cause underflow later in the function.

Just add the check and error out if get_size returns an error.

Reviewed-by: Paul Dale <ppzgs1@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24896)
crypto/rsa/rsa_oaep.c