commit | a83e4e2bf5fbb8607b292b6a880c050e3429decf | [log] [tgz] |
---|---|---|
author | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | Wed Jun 17 11:53:48 2015 +0200 |
committer | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | Wed Jun 17 14:27:38 2015 +0200 |
tree | 94f0fd3c71229400685ee29ffc635783fd1ad75b | |
parent | 27716cc1da66fbf98f212428998e7d8488eccb4e [diff] [blame] |
Extra check in verify_with_profile() This could happen if someone doesn't set the SSL configuration properly. In that case we don't want to segfault...
diff --git a/library/x509_crt.c b/library/x509_crt.c index 8a0bd8b..bedc6e9 100644 --- a/library/x509_crt.c +++ b/library/x509_crt.c
@@ -2160,6 +2160,9 @@ mbedtls_x509_name *name; mbedtls_x509_sequence *cur = NULL; + if( profile == NULL ) + return( MBEDTLS_ERR_X509_BAD_INPUT_DATA ); + *flags = 0; if( cn != NULL )