# PwnFilter rules.txt - Define Regular Expression Rules
# SAMPLE RULES http://dev.bukkit.org/server-mods/pwnfilter/
# NOTE: ALL MATCHES AUTOMATICALLY IGNORE CASE
# Each rule must have one 'match' statement and atleast one 'then' statement
# match <regular expression>
# ignore|require <user|permission|string|command> *(optional)
# then <replace|rewrite|warn|log|deny|debug|kick|kill|burn|command|console|lower> <string>
# For more details visit http://dev.bukkit.org/server-mods/pwnfilter/

# EXAMPLES

# URL FILTERING (Also catches emails so be careful) 
# IGNORE SOME URLS 
# USE CONSOLE TO BAN OFFENDER
match \b[a-zA-Z0-9\-\.]+\s?(\.|dot|\(dot\)|-|;|:|,)\s?(com|org|net|uk|cc|ws|ca|biz|mobi|xxx|tv)\b
ignore string minecraft.net|minecraftwiki.net|pwn9.com|google.com|yahoo.com
then console ban &player FOR (&rawstring)
then log

# IP ADDRESS FILTERING (Can also falsely identify long number strings
# USE CONSOLE TO BAN OFFENDER
match [0-9]{1,3}\s?(\.|dot|-|;|:|,|\s)\s?[0-9]{1,3}\s?(\.|dot|-|;|:|,|\s)\s?[0-9]{1,3}\s?(\.|dot|-|;|:|,|\s)\s?[0-9]{1,3}
then deny
then console ban &player FOR (&rawstring)
then log

# Replace F Bomb variants with fudge. Also catches ffffuuuccckkk
match f+u+c+k+|f+u+k+|f+v+c+k+|f+u+q+
then replace fudge
then kick Watch your language please
then log

# Replace a list of naughty words with random word! Let a certain permission swear.
match cunt|whore|fag|slut|queer|bitch|bastard
ignore permission permission.node
then randrep meep|beep|bleep|herp|derp

# FIX the .command typo with /command
match ^\.(?=[a-z]+)
then replace
then command

# Fun: rewrite tremor with pretty colors. Only let player tremor77 use it
match \btremor+\b|\btrem+\b
require user tremor77
then rewrite &bt&cREM&bor&f

# REPLACE CAPS over 6 characters long. (Short CAPS will be allowed like AFK and ASAP)
match (\p{Lu}|\s){7,120}
then lower

# CLEANUP REPETITION - trims aaaaaaaaaaa or lolololololol to shorter
match (.+)(?=\1\1\1+)
then replace

