Regex Help

These are old archives. They are kept for historic purposes only.
Post Reply
ctn|chrisw
Posts: 25
Joined: Wed Mar 10, 2004 9:24 am

Regex Help

Post by ctn|chrisw » Sat Apr 02, 2005 3:03 am

Ive been getting spammers lately spaming those free ipod crap things.

(20:31:15) <Penguin_man`> GET A FREE Flat screen, DS, PSP, Mac Mini, Motorola RAZOR AND MORE! GO TO > http://GrabFreeGear.com/index.php?referral=2098

I am crap with regexes, how would I have it automaticly kill anyone who does a message with "http://grabfreegear.com" in it?

Jason
Posts: 570
Joined: Mon Jun 14, 2004 5:09 pm

Post by Jason » Sat Apr 02, 2005 3:15 am

You would probably not want to just kill them, they would probably come right back. Heres for a 1 hour gline, change the time or reason to whatever you want, but keep the format

/spamfilter add cpnN gline 1h No_Spambots_Allowed http://GrabFreeGear\.com(/(index\.php(\?referral=[0-9]+)?)?)?$

That one will block any message ending with http://GrabFreeGear\.com[/[index.php[?referral=####]]]
[] means that this section may or may not appear.
There may be any number of #s (being a number of course)

As for your origional request (with gline):

/spamfilter add cpnN gline 1h No_Spambots_Allowed http://GrabFreeGear\.com

Your origional request, unaltered:

/spamfilter add cpnN kill - No_Spambots_Allowed http://GrabFreeGear\.com
Last edited by Jason on Sat Apr 02, 2005 3:16 am, edited 1 time in total.
Why the hell can't my signature be empty?
"Your message contains too few characters."

aquanight
Official supporter
Posts: 862
Joined: Tue Mar 09, 2004 10:47 pm
Location: Boise, ID

Post by aquanight » Sat Apr 02, 2005 3:16 am

/spamfilter add pcnN kill - Dont_Spam http://grabfreegear\.com

Yes you need the \ :P .

(Ok, scrub the case crap. I thought spamfilter used to be case-sensitive :/ .)

w00t
Posts: 1136
Joined: Thu Mar 25, 2004 3:31 am
Location: Nowra, Australia

Post by w00t » Sun Apr 03, 2005 4:24 am

Not that I know of... at least, not last time I read the docs ;)
-ChatSpike IRC Network [http://www.chatspike.net]
-Denora Stats [http://denora.nomadirc.net]
-Omerta [http://www.barafranca.com]

aquanight
Official supporter
Posts: 862
Joined: Tue Mar 09, 2004 10:47 pm
Location: Boise, ID

Post by aquanight » Sun Apr 03, 2005 5:45 am

About 99.9% of other regexp crap I have to deal with (VB, etc) default to case sensitive. So yeah :/ .

ctn|chrisw
Posts: 25
Joined: Wed Mar 10, 2004 9:24 am

Post by ctn|chrisw » Wed Apr 06, 2005 12:43 pm

thanks, and yeah the 1 hour gline will probably make sense, but once they spam they dont see to come back anyways if I manually kill them.

Post Reply