ChatFilter
ChatFilter
A chat filter for Bukkit, Spigot and Paper, 1.7.2 to 26.3. It censors or stops swearing in chat and in chat-like commands, sees through the usual disguises, blocks links and spam, and needs nothing installed on the client. Unmodified clients get all of it.
Also for NeoForge: ChatFilter ReForged, the same filter as a server-side mod for Minecraft 1.21.11 and 26.x.
Version 3 is a rebuild of this plugin, sharing its filtering engine with that mod. Most of what was asked for in these comments over the years is in it. Upgrading from 2.x: swap the jar. Your config and word lists are carried over on first start, the originals are kept as backups, and your old block or censor behaviour stays as it was.
Silent by default
A caught word reaches other players as ####. The sender sees exactly what they typed and is
told nothing, so there is nothing to argue with and nothing to work around. Staff with
chatfilter.see read the original.
Prefer the classic approach? Every category can instead:
- REPLACE the word for everyone (
!@$#,****or cartoon swearing) - SHADOW the whole line: a soft-mute where the sender sees it sent and nobody else sees it
- BLOCK it, with "Oi {player}! Mind your language!" if you like
- or just LOG it
Hard to get around
Capitals, accents, leetspeak (sh1t, $h!t), stretched letters (fuuuck), spelled-out letters
(f.u.c.k, s h i t), self-censoring (f*ck), full-width and look-alike letters from other
alphabets, zero-width characters, and colour codes hidden mid-word. List the plain word once.
Kind to innocent words
Part-word and whole-word lists, so ass catches neither class nor grass. There's an allowlist
for the Scunthorpe problem, and regular expressions for anything the lists can't say.
/chatfilter test <text> shows exactly what would be caught, by which entry, and what would happen.
Chat that arrives as a command
/msg, /tell, /w, /r, /me, /say, /mail send, /f chat, and anything else you list.
msg * skips the name: only the message is judged, never the player name, so /msg Assassin hi
works.
And the rest
- Links and IP addresses, including
example dot com, with an allowlist for your own site and a permission for those who may post them - Spam: shouting is lowercased, and repeats and floods are stopped
- Strikes that expire one at a time, and a ladder that can alert staff, warn the player, or run
any command:
mute {player} 10m,kick {player} - Staff alerts with a per-person toggle, and a console log
- Edit the lists in game:
/chatfilter add profanity.words …, saved to the config file - Keyword replies. It still answers "eleven", and you can switch that off for good.
Permissions
Plain Bukkit permissions, so any permissions plugin can grant them. The 2.x names (chatfilter.canswear, canchat, reload) still work.
| Node | Default | Means |
|---|---|---|
chatfilter.chat |
everyone | may chat at all |
chatfilter.bypass |
nobody | not filtered (ops included) |
chatfilter.see |
nobody | reads masked words as written |
chatfilter.links |
nobody | may post links |
chatfilter.alerts |
ops | receives staff alerts |
chatfilter.admin |
ops | uses /chatfilter |
Configuration
plugins/ChatFilter/config.yml, every option commented. The defaults mask the classic word list
silently, block links and floods, quieten shouting, and filter the usual private-message commands.
The severe list ships empty: every server's is different, and nobody should get one they didn't
choose.
Versions
Two files: 1.13 – 26.3 (+bukkit1.13-26.3) and 1.7.2 – 1.12.2 (+bukkit1.7-1.12). Tested
on Paper 1.7.10, 1.8.8, 1.12.2, 1.16.5, 1.20.1, 1.21.11, 26.1.2 and 26.3.
Open source (MIT): GitHub.
-
View User Profile
-
Send Message
Posted Mar 23, 2014@jjkrause
Have you tried "/gamerule commandBlockOutput false" ?
-
View User Profile
-
Send Message
Posted Mar 23, 2014@SableDnah
The example I gave you was a direct message yes... but there are others that appear for everybody, such as [CONSOLE: Given JUMP ( ID 8 ) to JasonKrause for 30 seconds] when using the effect command from console... If I could block everything starting with certain words, that would be awesome!
In the above example, I could block "[CONSOLE: Given*" and that would block all effect commands.
-
View User Profile
-
Send Message
Posted Mar 20, 2014@jjkrause
Thats a direct message to the player - not broadcast chat.
I could add a list of entire sentences to look out for tho and block those.. will see what i can do.
-
View User Profile
-
Send Message
Posted Mar 20, 2014@MURD3RUS
That would be awesome, but hard - at the moment the same message is sent to "broadcast" chat. I'd have to block that if there was a swear and instead manually message each player the filtered or unfiltered test. Its a bit of a hack - and would break a lot of other chat plugins as they would no longer be "chats"... but its a great idea so i will think on it further.
-
View User Profile
-
Send Message
Posted Mar 20, 2014I'm looking for a filter program that will remove text generated by commands. Example: I have a command block that clears a person's inventory using /clear @p -a. In that person's chat, he sees "Your inventory has been cleared by @". Would it be possible to filter any output from any commands?
-
View User Profile
-
Send Message
Posted Mar 20, 2014Can you add a permission so, only certain people can SEE swears?? That'd be really fresh.
-
View User Profile
-
Send Message
Posted Feb 25, 2013Doesn't work with herochat anymore.
Any plans for updating this great plugin?
-
View User Profile
-
Send Message
Posted Jan 4, 2013@Krevex
Yeah - chatfilter grew out of an easter egg in MobHealth till it got its own plugin.
-
View User Profile
-
Send Message
Posted Dec 13, 2012Plugin works great with towny. Nice work, something i found in the plugin.yml though made me laugh =)
chatfilter.*: description: Gives access to all MobHealth commands/functions. children:
-
View User Profile
-
Send Message
Posted Aug 21, 2012This plugin no longer seams to filter herochat for me. Luckily HeroChat has its own filter, even if it is a bit different to use. Thanks for this plugin!
-
View User Profile
-
Send Message
Posted Jul 16, 2012I would like to make it where even operators cant swear, including me. Anyone know how?
-
View User Profile
-
Send Message
Posted Jul 8, 2012Works great, also with PEX, all permissions are working.
My members can swear, but not my guests.
Request:
Option to block Shit, s h i t, s.h.i.t. etc...
Possible?
And . (dot) doesn't work, so I couldn't block or censor .to (address.something.to)
Format: UTF8-Without BOM
Question:
profanityMessage <- Only the swearer could see this message, possible to make a permission.node, who can see the text?
blockMessage: <- Who could see this message? no one? Never seen.... Possible to show this only to the swearer?
-
View User Profile
-
Send Message
Posted Jun 26, 2012@awesomebilly
Always had trouble with pex. I'll investigate and let you know how it goes.
-
View User Profile
-
Send Message
Posted Jun 25, 2012- chatfilter.canswear
does not work with pex
-
View User Profile
-
Send Message
Posted May 23, 2012thank you :3
-
View User Profile
-
Send Message
Posted May 22, 2012<<reply 717329="">>
Having problems replicating your issue.
I've raised a ticket - http://dev.bukkit.org/server-mods/chatfilter/tickets/1-at-the-beginning-of-a-message/ if you could add more info there that'd be great.
-
View User Profile
-
Send Message
Posted May 21, 2012@SableDnah
Thanks for the quick response. Adding ` to the censor didn't work, so I look forward to your fix.
-
View User Profile
-
Send Message
Posted May 20, 2012@tmad40blue I can definitely fix that. Will get in touch if I need more info. Meanwhile i'll get a fix out soon.
btw - try adding ` to the profanity filter. Not sure if it'll work - but it might do.
-
View User Profile
-
Send Message
Posted May 20, 2012@srmorris2
Yeah work on command text filtering is underway.
-
View User Profile
-
Send Message
Posted May 20, 2012If you put ` at the beginning of a message, the entire message goes uncensored. This is unacceptable – several of my members have figured out how to completely bypass this plugin by typing one character in their messages.
If this isn't fixed then I'll be exploring other options =(