Reject u@@h klines.

This commit is contained in:
Jilles Tjoelker 2008-05-21 23:00:10 +02:00
parent 1dc9ac1d69
commit aeeda4466a
1 changed files with 3 additions and 2 deletions

View File

@ -589,8 +589,9 @@ find_user_host(struct Client *source_p, const char *userhost, char *luser, char
static int static int
valid_user_host(struct Client *source_p, const char *luser, const char *lhost) valid_user_host(struct Client *source_p, const char *luser, const char *lhost)
{ {
/* # is invalid, as is '!' (n!u@h kline) */ /* # is invalid, as are '!' (n!u@h kline) and '@' (u@@h kline) */
if(strchr(lhost, '#') || strchr(luser, '#') || strchr(luser, '!')) if(strchr(lhost, '#') || strchr(luser, '#') || strchr(luser, '!') ||
strchr(lhost, '@'))
{ {
sendto_one_notice(source_p, ":Invalid K-Line"); sendto_one_notice(source_p, ":Invalid K-Line");
return 0; return 0;