]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Fixed broken display of 'aes enabled'
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Mon, 19 Dec 2005 15:25:40 +0000 (15:25 +0000)
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Mon, 19 Dec 2005 15:25:40 +0000 (15:25 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2575 e03df62e-2008-0410-955e-edbf42e46eb7

src/modules/m_spanningtree.cpp

index 09a3b2c56b2a0b302e62d858c3dbc290621f2b4c..10da3222c27924a025572f9f8bf84073e144523f 100644 (file)
@@ -572,7 +572,7 @@ class TreeSocket : public InspSocket
                this->LinkState = WAIT_AUTH_1;
        }
 
-       void InitAES(std::string key)
+       void InitAES(std::string key,std::string SName)
        {
                if (key == "")
                        return;
@@ -588,11 +588,6 @@ class TreeSocket : public InspSocket
                }
                else
                {
-                       std::string SName = myhost;
-                       if (InboundServerName != "")
-                       {
-                               SName = InboundServerName;
-                       }
                        WriteOpers("\2AES\2: Initialized %d bit encryption to server %s",keylength*8,SName.c_str());
                        ctx->MakeKey(key.c_str(), "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\
                                \0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", keylength, keylength);
@@ -618,7 +613,7 @@ class TreeSocket : public InspSocket
                                        if (x->EncryptionKey != "")
                                        {
                                                this->WriteLine("AES "+Srv->GetServerName());
-                                               this->InitAES(x->EncryptionKey);
+                                               this->InitAES(x->EncryptionKey,x->Name);
                                        }
                                        /* found who we're supposed to be connecting to, send the neccessary gubbins. */
                                        this->WriteLine("SERVER "+Srv->GetServerName()+" "+x->SendPass+" 0 :"+Srv->GetServerDescription());
@@ -1719,7 +1714,7 @@ class TreeSocket : public InspSocket
                         {
                                 if ((x->EncryptionKey != "") && (x->Name == sserv))
                                 {
-                                        this->InitAES(x->EncryptionKey);
+                                        this->InitAES(x->EncryptionKey,sserv);
                                 }
                         }
                         return true;