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

- A warning is now sent to the oper if (s)he tries to add a (G)ZLINE on *@host.

(G)ZLINES should have an ipmask, not a hostmask, because they are processed BEFORE
  any dns lookups are done.
This commit is contained in:
Bram Matthys
2005-02-27 22:39:51 +00:00
parent 6afa0da62b
commit 914f6cceb3
2 changed files with 21 additions and 0 deletions
+6
View File
@@ -716,3 +716,9 @@
So use with care on mixed-version nets.
- Fixed /(G)ZLINE [nick] placing the *line on *@host instead of *@IP, reported by
Snake (#0002246).
- A warning is now sent to the oper if (s)he tries to add a (G)ZLINE on *@host.
(G)ZLINES should have an ipmask, not a hostmask, because they are processed BEFORE
any dns lookups are done. Therefore any (g)zlines placed will probably work
(but not necessarily) for like an hour (or whatever TTL), but after that the
(ab)user can get in again so this is usually not what you want ;).
I suppose I'll add a FAQ entry about this.
+15
View File
@@ -447,6 +447,21 @@ DLLFUNC int m_tkl_line(aClient *cptr, aClient *sptr, int parc, char *parv[], ch
hostmask = usermask;
usermask = "*";
}
if ((*type == 'z') || (*type == 'Z'))
{
/* It's a (G)ZLINE, make sure the user isn't specyfing a HOST.
* Just a warning for now, but perhaps in 3.2.4 we should make this an error.
*/
for (p=hostmask; *p; p++)
if (isalpha(*p))
{
sendnotice(sptr, "WARNING: (g)zlines should be placed on user@IPMASK, not user@hostmask "
"(this is because (g)zlines are processed BEFORE a dns lookup is done)");
break;
}
}
/* set 'p' right for later... */
p = hostmask-1;
}
else