These are old archives. They are kept for historic purposes only.
-
Albatoor
- Posts: 5
- Joined: Tue Apr 10, 2007 5:16 pm
Post
by Albatoor »
Hi all,
I'm trying to do some spamfilter with regex but it's so difficult for me
I want to allow the !adduser command, but with only 2 options, like
!adduser 1 2, if not have 2 options, command don't show
Thanx
-
Jobe
- Official supporter
- Posts: 1180
- Joined: Wed May 03, 2006 7:09 pm
- Location: United Kingdom
Post
by Jobe »
Code: Select all
/spamfilter add c block - Invalid_format ^!adduser [^ ]+ [^ ]+$
Should work in theory.
-
Albatoor
- Posts: 5
- Joined: Tue Apr 10, 2007 5:16 pm
Post
by Albatoor »
With your, spam is detect only when i have the 2 command, i want the contrary
-
Albatoor
- Posts: 5
- Joined: Tue Apr 10, 2007 5:16 pm
Post
by Albatoor »
^!adduser[[:space:]][:sigraph:]$
^!adduser \S$
Didn't work, why ?
-
Jobe
- Official supporter
- Posts: 1180
- Joined: Wed May 03, 2006 7:09 pm
- Location: United Kingdom
Post
by Jobe »
Ooops my bad. lol
I dont know then. Sorry
-
Albatoor
- Posts: 5
- Joined: Tue Apr 10, 2007 5:16 pm
Post
by Albatoor »
^!adduser [^ ]+ $
^!adduser [^ ]+$ or ^!adduser \S+$
It's ok with this 2 regex, First blok !adduser xxx [space]
and second, !adduser xxx
Now, can you help me about setup badword on xxx ?
Thanx
-
Jason
- Posts: 570
- Joined: Mon Jun 14, 2004 5:09 pm
Post
by Jason »
Badwords don't need to use regular expressions. They can be normal glob matching.
Why the hell can't my signature be empty?
"Your message contains too few characters."
-
Albatoor
- Posts: 5
- Joined: Tue Apr 10, 2007 5:16 pm
Post
by Albatoor »
hum ok, and can I use regex on badword ? Exemple I need to block the word starting by shit when it's at the end of the sentences ...
I have try : shit.*+$ but doesnt work
Any idea ?
Thanx again
-
SpaceDoG
- Posts: 301
- Joined: Mon Feb 27, 2006 5:44 am
-
Contact:
Post
by SpaceDoG »
Albatoor you don't need a spamfilter for badwords. Just force all channels/users to be +G and add your badwords to the badwords list.