Don't crash if there are no trusted certs
authorMatt Caswell <matt@openssl.org>
Wed, 18 Apr 2018 13:20:29 +0000 (14:20 +0100)
committerMatt Caswell <matt@openssl.org>
Thu, 19 Apr 2018 07:57:44 +0000 (08:57 +0100)
commitc02a03bff851cd17c51812643cd1964b7da007f3
treea48ca852ecb8f88158a8cd67ccaf3feb5408be85
parent2add645dfc364cfc609e6138de1bf43c217bb557
Don't crash if there are no trusted certs

The X509_STORE_CTX_init() docs explicitly allow a NULL parameter for the
X509_STORE. Therefore we shouldn't crash if we subsequently call
X509_verify_cert() and no X509_STORE has been set.

Fixes #2462

Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/6002)
crypto/x509/x509_lu.c