From: Peter Powell Date: Mon, 26 Nov 2018 14:33:44 +0000 (+0000) Subject: Only check if a SSL cert is usable if we're getting the fp. X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=95749975408a985d6a6a9ff53bbf3592c90b8649;p=user%2Fhenk%2Fcode%2Finspircd.git Only check if a SSL cert is usable if we're getting the fp. --- diff --git a/include/modules/ssl.h b/include/modules/ssl.h index edea45a10..69bd65009 100644 --- a/include/modules/ssl.h +++ b/include/modules/ssl.h @@ -195,9 +195,7 @@ class SSLIOHook : public IOHook */ ssl_cert* GetCertificate() const { - if (certificate && certificate->IsUsable()) - return certificate; - return NULL; + return certificate; } /** @@ -208,7 +206,7 @@ class SSLIOHook : public IOHook std::string GetFingerprint() const { ssl_cert* cert = GetCertificate(); - if (cert) + if (cert && certificate->IsUsable()) return cert->GetFingerprint(); return ""; }