summaryrefslogtreecommitdiff
path: root/src/userprocess.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-01-27 15:26:59 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-01-27 15:26:59 +0000
commit653638c68684ec035fd58bc2d0d91c9bf9aa2ab9 (patch)
tree364fd9cce4e2e8d6e86ddc3f1267b98dbed51854 /src/userprocess.cpp
parent469c2e7f5ad7d3f4d7d150d643ce363a650f19b9 (diff)
Improved IP handling. Now uses in_addr to store client ip, not char[16]!
Added global and local session limits All of this needs TESTING. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2934 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/userprocess.cpp')
-rw-r--r--src/userprocess.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/userprocess.cpp b/src/userprocess.cpp
index c7e7aa545..29560871f 100644
--- a/src/userprocess.cpp
+++ b/src/userprocess.cpp
@@ -148,9 +148,9 @@ void ProcessUser(userrec* cu)
}
else
{
- WriteOpers("*** Excess flood from %s",current->ip);
- log(DEFAULT,"Excess flood from: %s",current->ip);
- add_zline(120,Config->ServerName,"Flood from unregistered connection",current->ip);
+ WriteOpers("*** Excess flood from %s",(char*)inet_ntoa(current->ip4));
+ log(DEFAULT,"Excess flood from: %s",(char*)inet_ntoa(current->ip4));
+ add_zline(120,Config->ServerName,"Flood from unregistered connection",(char*)inet_ntoa(current->ip4));
apply_lines(APPLY_ZLINES);
}
return;
@@ -163,9 +163,9 @@ void ProcessUser(userrec* cu)
}
else
{
- WriteOpers("*** Excess flood from %s",current->ip);
- log(DEFAULT,"Excess flood from: %s",current->ip);
- add_zline(120,Config->ServerName,"Flood from unregistered connection",current->ip);
+ WriteOpers("*** Excess flood from %s",(char*)inet_ntoa(current->ip4));
+ log(DEFAULT,"Excess flood from: %s",(char*)inet_ntoa(current->ip4));
+ add_zline(120,Config->ServerName,"Flood from unregistered connection",(char*)inet_ntoa(current->ip4));
apply_lines(APPLY_ZLINES);
}
return;
@@ -197,7 +197,7 @@ void ProcessUser(userrec* cu)
}
else
{
- add_zline(120,Config->ServerName,"Flood from unregistered connection",current->ip);
+ add_zline(120,Config->ServerName,"Flood from unregistered connection",(char*)inet_ntoa(current->ip4));
apply_lines(APPLY_ZLINES);
}
return;