summaryrefslogtreecommitdiff
path: root/src/inspircd.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-15 12:07:02 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-15 12:07:02 +0000
commitf72964d7bff8b39185cdf05652bdc9f2ced0e8cf (patch)
tree255417a6b459a0e8311b2820966f79ff71b2313d /src/inspircd.cpp
parent909a720b0763137c28d3261db45e004c96cf566e (diff)
Mesh authcookie fixes
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@604 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/inspircd.cpp')
-rw-r--r--src/inspircd.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/inspircd.cpp b/src/inspircd.cpp
index dcab93c1e..6eb01466a 100644
--- a/src/inspircd.cpp
+++ b/src/inspircd.cpp
@@ -6618,6 +6618,25 @@ void handle_link_packet(char* udp_msg, char* udp_host, serverrec *serv)
if (auth_cookies[u] == atoi(cookie))
{
WriteOpers("Allowed cookie from %s, is now part of the mesh",servername);
+
+
+ for (int j = 0; j < 32; j++)
+ {
+ if (me[j] != NULL)
+ {
+ for (int k = 0; k < me[j]->connectors.size(); k++)
+ {
+ if (!strcasecmp(me[j]->connectors[k].GetServerName().c_str(),udp_host))
+ {
+ me[j]->connectors[k].SetServerName(servername);
+ }
+ }
+ }
+ WriteOpers("\2WARNING!\2 %s sent us an authentication packet but we are not authenticating with this server right noe! Possible intrusion attempt!",udp_host);
+ return;
+ }
+
+
return;
}
}