summaryrefslogtreecommitdiff
path: root/src/commands.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-03-28 13:35:16 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2005-03-28 13:35:16 +0000
commitdcafa1a379bab45d623d365706491ccf59cd61e6 (patch)
tree326fb8750b79ce99b11137fbbf0eb7f39bdccc2b /src/commands.cpp
parentfe08337b1f68ba2b9e82eaaae708a8ff12b6e1f0 (diff)
Fixed to actually CHECK THE PASSWORD of linking servers!
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@929 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/commands.cpp')
-rw-r--r--src/commands.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/commands.cpp b/src/commands.cpp
index 9385ae3f3..7eed17478 100644
--- a/src/commands.cpp
+++ b/src/commands.cpp
@@ -2847,7 +2847,7 @@ void handle_link_packet(char* udp_msg, char* tcp_host, serverrec *serv)
ConfValue("link","sendpass",i,Link_SendPass,&config_f);
log(DEBUG,"(%d) Comparing against name='%s', ipaddr='%s', port='%s', recvpass='%s'",i,Link_ServerName,Link_IPAddr,Link_Port,Link_Pass);
LinkPort = atoi(Link_Port);
- if (!strcasecmp(Link_ServerName,servername))
+ if ((!strcasecmp(Link_ServerName,servername)) && (!strcmp(Link_Pass,password)))
{
// we have a matching link line -
// send a 'diminutive' server message back...
@@ -2971,7 +2971,7 @@ void handle_link_packet(char* udp_msg, char* tcp_host, serverrec *serv)
ConfValue("link","sendpass",i,Link_SendPass,&config_f);
log(DEBUG,"(%d) Comparing against name='%s', ipaddr='%s', port='%s', recvpass='%s'",i,Link_ServerName,Link_IPAddr,Link_Port,Link_Pass);
LinkPort = atoi(Link_Port);
- if (!strcasecmp(Link_ServerName,servername))
+ if ((!strcasecmp(Link_ServerName,servername)) && (!strcmp(Link_Pass,password)))
{
// matching link at this end too, we're all done!
// at this point we must begin key exchange and insert this