diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2015-06-05 12:11:25 +0100 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2015-06-11 13:07:42 +0100 |
commit | 92f9a8bf3844359bb50d86dab92bc24b074d350d (patch) | |
tree | d351cdbe1a1cc142bab16be49fbe3ca6a945dc17 | |
parent | 39bcfb129e816de00bf2170c3497e8104767beb7 (diff) | |
download | openssl-new-92f9a8bf3844359bb50d86dab92bc24b074d350d.tar.gz |
Fix infinite loop in CMS
Fix loop in do_free_upto if cmsbio is NULL: this will happen when attempting
to verify and a digest is not recognised. Reported by Johannes Bauer.
CVE-2015-1792
Reviewed-by: Matt Caswell <matt@openssl.org>
-rw-r--r-- | crypto/cms/cms_smime.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/cms/cms_smime.c b/crypto/cms/cms_smime.c index ecb05c437e..9717789e3c 100644 --- a/crypto/cms/cms_smime.c +++ b/crypto/cms/cms_smime.c @@ -131,7 +131,7 @@ static void do_free_upto(BIO *f, BIO *upto) BIO_free(f); f = tbio; } - while (f != upto); + while (f && f != upto); } else BIO_free_all(f); } |