diff options
author | Rob Percival <robpercival@google.com> | 2016-03-03 16:08:01 +0000 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2016-03-04 10:50:10 -0500 |
commit | 0c6ea56568f8dbc5d83cd737d81cd7362295acf0 (patch) | |
tree | 87223eb4caeec09c436d01a0e7abe056d23ce265 /crypto/ct/ct_log.c | |
parent | a930afb6986fb8e22a59b2bfc5f1a19a8dc3388d (diff) |
Handle missing "enabled_logs" line in CT log file
Reviewed-by: Ben Laurie <ben@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'crypto/ct/ct_log.c')
-rw-r--r-- | crypto/ct/ct_log.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/crypto/ct/ct_log.c b/crypto/ct/ct_log.c index f5a01fdbd3..1a98c7a0bd 100644 --- a/crypto/ct/ct_log.c +++ b/crypto/ct/ct_log.c @@ -245,6 +245,12 @@ int CTLOG_STORE_load_file(CTLOG_STORE *store, const char *file) } enabled_logs = NCONF_get_string(load_ctx->conf, NULL, "enabled_logs"); + if (enabled_logs == NULL) { + ret = 0; + CTerr(CT_F_CTLOG_STORE_LOAD_FILE, CT_R_LOG_CONF_INVALID); + goto end; + } + ret = CONF_parse_list(enabled_logs, ',', 1, ctlog_store_load_log, load_ctx); if (ret == 1 && load_ctx->invalid_log_entries > 0) { ret = 0; |