Block a nick

These are old archives. They are kept for historic purposes only.
Post Reply
Guest

Block a nick

Post by Guest » Tue Aug 23, 2005 4:46 pm

Hi there...

How can i block a nick with spamfilter?

For example:

The bots that connects to my server are botnets as far as i know. And most of tham have nick like coming from every Country

Example: USA|457842, BRA|635986, FRA|421598 etc..
So, the thing is all of tham have 6 numbers at the end

I treid to gline tham this way:

spamfilter {
regex "^[a-z]\|\[0-9]{3,6}";
target { user; };
action gline;
ban-time 1d;
reason "Posible botnet!";
};


but the thing is it glines also other users like neo| or neo|23

What am i doing wrong? :?

I would like to gline only the nick that have 6 numbers at the end like USA|123456 or ABC|123456

Stealth
Head of Support
Posts: 2086
Joined: Tue Jun 15, 2004 8:50 pm
Location: Chino Hills, CA, US
Contact:

Post by Stealth » Tue Aug 23, 2005 7:39 pm

Try this as your regex:

Code: Select all

^(USA|BRA|FRA)\|\d{6}!
This will block all the nicks starting with USA, BRA, and FRA. You can add more prefixes by separating them with a |.

If there are too many prefixes, you can use this regex:

Code: Select all

^[A-Z]{3}\|\d{6}!
This will block anyone with 3 letters, a |, and 6 numbers at the end.

Guest

Block a nick

Post by Guest » Thu Aug 25, 2005 8:13 pm

Stealth

Thx for the code its working fine. I've tested it my self
Thank you :D

Post Reply