1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-07 07:23:13 +02:00

Fixed a maxperip and maxunknownconnectionsperip bug in IPv6

This commit is contained in:
codemastr
2002-06-04 16:46:45 +00:00
parent 18892b6446
commit c27a3229c7
3 changed files with 9 additions and 0 deletions
+1
View File
@@ -1320,3 +1320,4 @@ seen. gmtime warning still there
than by host the hostname is still used for the u@h, unless allow::options::useip is set
(idea inspired by danielek)
- Fixed a bug in the new allow system reported by danielek
- Fixed a maxperip and a maxunknownconnectionsperip bug in IPv6 reported by danielek
+4
View File
@@ -1194,7 +1194,11 @@ add_con_refuse:
for (i = LastSlot; i >= 0; i--)
{
if (local[i] && IsUnknown(local[i]) &&
#ifndef INET6
local[i]->ip.S_ADDR == acptr->ip.S_ADDR)
#else
!bcmp(local[i]->ip.S_ADDR, cptr->ip.S_ADDR, sizeof(cptr->ip.S_ADDR)))
#endif
{
j++;
if (j > MAXUNKNOWNCONNECTIONSPERIP)
+4
View File
@@ -3977,7 +3977,11 @@ int AllowClient(aClient *cptr, struct hostent *hp, char *sockhost)
ii = 1;
for (i = LastSlot; i >= 0; i--)
if (local[i] && MyClient(local[i]) &&
#ifndef INET6
local[i]->ip.S_ADDR == cptr->ip.S_ADDR)
#else
!bcmp(local[i]->ip.S_ADDR, cptr->ip.S_ADDR, sizeof(cptr->ip.S_ADDR)))
#endif
{
ii++;
if (ii > aconf->maxperip)