Page 1 of 1

blocking text which has no spaces

Posted: Thu Mar 22, 2007 6:42 pm
by LetSDie
ok here is the problem
i am using this code for blocking messages if it has no spaces between words ;

Code: Select all

spamfilter { 
regex "^[A-Z]{12}.+$"; 
target { private; channel; }; 
action block; 
reason "14Bosluk kullanmadan cok uzun yazi yazdiniz..1 Boşluk Kullanmadan Kullana Bileceğiniz Karakter sayısı 12dir.4HoSSohbetler"; 
}; 
but this code doesn't blocks text like these;

Code: Select all

<ekeke> Hangi-anası-nı-zıktıım-bana-Söwüosa-Nick-Yazsın-Anaaaaaaan-@mına-Korum-Orspu-cucuu :* :* baban Hangi-anası-nı-zıktıım-bana-Söwüosa-Nick-Yazsın-Anaaaaaaan-@mına-Korum-Orspu-cucuu :* :* baban 
what can i do?

Posted: Thu Mar 22, 2007 10:48 pm
by Jobe
Try this instead:

^[\S]{12}.+$

[\S] = anything other then a space

http://www.vulnscan.org/UnrealIRCd/unre ... egexassert

Posted: Fri Mar 23, 2007 5:44 pm
by JanisB
<JanisB> Congratulations!
16 symbols, i've got banned :<

Posted: Sat Mar 24, 2007 2:11 am
by Stealth
Because it's [^\s] you want

Code: Select all

[^\s]{12}
Don't need the ^/$ or the .+, unless you mean for only the first word to be matched, BUT it will block ANY linen with a word more than 12 characters.

IMO, this would be a dumb spamfilter... You need to find soemthing a little more specific