diff options
author | Gilles Chehade <gilles@poolp.org> | 2015-05-03 17:52:08 +0200 |
---|---|---|
committer | Gilles Chehade <gilles@poolp.org> | 2015-05-03 17:52:08 +0200 |
commit | 302f02018404dfc04185222dc23a1eb613fa0950 (patch) | |
tree | e4fa7f676dd240601664fd562bfc417326e96e3c | |
parent | turn the lka certificate verification into an async operation (diff) | |
download | OpenSMTPD-302f02018404dfc04185222dc23a1eb613fa0950.tar.xz OpenSMTPD-302f02018404dfc04185222dc23a1eb613fa0950.zip |
it's ok not ot have a pki entry there
-rw-r--r-- | smtpd/lka.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/smtpd/lka.c b/smtpd/lka.c index 27c8c07c..1bc743bd 100644 --- a/smtpd/lka.c +++ b/smtpd/lka.c @@ -682,9 +682,10 @@ lka_certificate_verify_resume(enum imsg_type type, struct ca_vrfy_req_msg *req) size_t i; resp.reqid = req->reqid; - pki = dict_xget(env->sc_pki_dict, req->pkiname); cafile = CA_FILE; - if (pki->pki_ca_file) + + pki = dict_get(env->sc_pki_dict, req->pkiname); + if (pki && pki->pki_ca_file) cafile = pki->pki_ca_file; if (! lka_X509_verify(req, cafile, NULL)) resp.status = CA_FAIL; |