summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-04-09 17:11:33 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-04-09 17:11:33 +0000
commit3a89c8e89e6612c06eb91e68c30a280b8f593aa7 (patch)
treef15a177fcf9a2359a56b51384f0ea03716bd87ca /src/modules/m_spanningtree
parent7f00015727fab50e37de46aa90d218b31c852c87 (diff)
Handle non-hmac servers smarter without having to globally turn off hmac
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6777 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/treesocket2.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/treesocket2.cpp b/src/modules/m_spanningtree/treesocket2.cpp
index 6c0418a0b..3ff981544 100644
--- a/src/modules/m_spanningtree/treesocket2.cpp
+++ b/src/modules/m_spanningtree/treesocket2.cpp
@@ -851,7 +851,7 @@ bool TreeSocket::Outbound_Reply_Server(std::deque<std::string> &params)
std::string description = params[3];
for (std::vector<Link>::iterator x = Utils->LinkBlocks.begin(); x < Utils->LinkBlocks.end(); x++)
{
- if ((x->Name == servername) && (ComparePass(this->MakePass(x->RecvPass,this->GetOurChallenge()),password)))
+ if ((x->Name == servername) && ((ComparePass(this->MakePass(x->RecvPass,this->GetOurChallenge()),password)) || (x->RecvPass == password && (this->GetTheirChallenge().empty()))))
{
TreeServer* CheckDupe = Utils->FindServer(sname);
if (CheckDupe)
@@ -900,7 +900,7 @@ bool TreeSocket::Inbound_Server(std::deque<std::string> &params)
std::string description = params[3];
for (std::vector<Link>::iterator x = Utils->LinkBlocks.begin(); x < Utils->LinkBlocks.end(); x++)
{
- if ((x->Name == servername) && (ComparePass(this->MakePass(x->RecvPass,this->GetOurChallenge()),password)))
+ if ((x->Name == servername) && ((ComparePass(this->MakePass(x->RecvPass,this->GetOurChallenge()),password) || x->RecvPass == password && (this->GetTheirChallenge().empty()))))
{
TreeServer* CheckDupe = Utils->FindServer(sname);
if (CheckDupe)