summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-10-30 22:48:51 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-10-30 22:48:51 +0000
commit83a688082ed4912000e6e3a9966060099e3e0c06 (patch)
tree9d4478f7193f7879cfbef195feb683759534c877
parent4171efac1782a31ba41425e630956db185fc4783 (diff)
Fix for crash found by eggy when a user without a cert tries to oper on a fingerprinted oper tag
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5593 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/modules/extra/m_ssl_oper_cert.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/extra/m_ssl_oper_cert.cpp b/src/modules/extra/m_ssl_oper_cert.cpp
index 23314ec57..220469e2f 100644
--- a/src/modules/extra/m_ssl_oper_cert.cpp
+++ b/src/modules/extra/m_ssl_oper_cert.cpp
@@ -145,7 +145,7 @@ class ModuleOperSSLCert : public Module
if ((!strcmp(LoginName,parameters[0])) && (!ServerInstance->OperPassCompare(Password,parameters[1])) && (OneOfMatches(TheHost,TheIP,HostName)))
{
/* This oper would match */
- if (cert->GetFingerprint() != FingerPrint)
+ if ((!cert) || (cert->GetFingerprint() != FingerPrint))
{
user->WriteServ("491 %s :This oper login name requires a matching key fingerprint.",user->nick);
ServerInstance->SNO->WriteToSnoMask('o',"'%s' cannot oper, does not match fingerprint", user->nick);