[INACTIVE][CHAT] RegexFilter v1.05 - Regular expression chat filter [432-860]

Discussion in 'Inactive/Unsupported Plugins' started by FloydATC, Feb 19, 2011.

  1. Offline


    RegexFilter - Regular Expression chat filter
    Version: v1.05

    This plugin uses the power of Regular Expressions to filter anything you want from chat. Matching messages can be rewritten, logged and blocked, depending on the rules you define. Stop yourself from accidently sending those embarrasing .commands to chat. Warn users who use bad language and even turn their profanities into harmless language.

    This plugin comes with a default setup that effectively replaces my dotFilter and 7filter plugins, which will no longer be maintained.

    • Command typos beginning with certain characters can be stopped (like . and 7)
    • Optionally recover those typos and execute the command as intended
    • Define your own macros or command aliases
    • Simple but powerful configuration with built-in debugging
    • Each regular expression is compiled only once => very fast
    • Supports config reload with "/regex reload"
    • Permissions aware, rules may apply to players, groups or permission nodes
    • Automatically kick players
    • Still no cake
    Download http://minecraft.atc.no/plugins/RegexFilter.jar

    Source code is included - no strings attached, no warranties implied

    Version 1.00
    • Original release
    Version 1.01
    • Changed priority to "lowest" for compatibility with iChat
    Version 1.02
    • Added "/regex reload" command and "then debug" statement
    Version 1.03
    • Removed the "stupidly long constructor" as per Bukkit team recommendation
    Version 1.04
    • Added "then command" to convert chat messages into commands
    Version 1.05
    • Added permission awareness, "then kick" and "then abort"
    • Download and copy to your "plugins" directory
    • Optionally create the directory "plugins/RegexPlugin"
    • Optionally create the file "plugins/RegexPlugin/rules.txt" and edit

    # Each rule must have one 'match' statement and atleast one 'then' statement
    # match <regular expression>
    # ignore user|group [space separated list]
    # ignore permission [node]
    # require user|group [space separated list]
    # require permission [node]
    # then replace <string>|warn [<string>]|log|deny|debug|kick|abort
    # Example 1:
    match f+u+c+k+
    then replace cluck
    then warn Watch your language please
    then log
    # Example 2:
    match dick
    then replace duck
    # Emulate DotFilter
    match ^\.[a-z]+
    then warn
    then deny
    # Emulate 7Filter
    match ^7[a-z]+
    then warn
    then deny
    # Quietly turn "(command" into "/command"
    match ^\((?=[a-z]+)
    then replace
    then command
    Please do NOT post questions here about how to write regular expressions, there are thousands of web sites discussing this topic. Google is your friend. The plugin uses java.util.regex and is CASE_INSENSITIVE. It is NOT possible to use parens to capture substrings to be used with replace. ALL matching rules are applied in the order they appear before any action is taken.
  2. broken link is broken...
  3. Offline



    Updating this for the newest RB would be AWESOME...or at least making sure it works with the latest...I haven't tested it yet...

    I guess I should.
  4. Offline


    Working 100% fine here.
  5. Offline


    Awesome. I'll give it a try.

  6. Offline


    Working good. Is there a way to add a certain match to an exception for a filter? I have my own regex code to match domains, but i would like to have it if someone said the domain of my own server that it wouldnt get filtered.
  7. Offline


    Oh, here is something i thought about:

    since /mute is a toggle, and if i had it this as
    match <ip regex>
    then mute
    then log
    would it toggle the mute every time they say the natch?

    In the console, ive noticed someone got caught by this, and then i manually muted him, but even though he is still muted, it still shows the [Filter] line right above the mute. So it seems his message is still getting through, but again, will the mute toggle for him?
  8. Offline


    Write "then deny" to block that message.
  9. Offline


    Good ol' times
    I miss this plugin so much
    DreamPhreak likes this.
  10. Offline


    Do you still have the source?? any github link??
  11. Offline


    The source is included in the jar.
  12. Offline


    Last edited by a moderator: May 9, 2016

Share This Page