fetch_curl_report_certs_upstream: Use new SSL_CERT_ERR_CERT_MISSING

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
This commit is contained in:
Daniel Silverstone 2019-12-03 09:42:14 +00:00
parent 6f105c41c2
commit 3a8317fddb
No known key found for this signature in database
GPG Key ID: C30DF439F2987D74
1 changed files with 5 additions and 1 deletions

View File

@ -482,7 +482,11 @@ fetch_curl_report_certs_upstream(struct curl_fetch_info *f)
memset(ssl_certs, 0, sizeof(ssl_certs));
for (depth = 0; depth <= f->cert_depth; depth++) {
assert(certs[depth].cert != NULL);
if (certs[depth].cert == NULL) {
/* This certificate is missing, skip it */
ssl_certs[depth].err = SSL_CERT_ERR_CERT_MISSING;
continue;
}
/* get certificate version */
ssl_certs[depth].version = X509_get_version(certs[depth].cert);