Badword block

From UnrealIRCd documentation wiki
Jump to navigation Jump to search

The badword block allows you to manipulate the list used for user and channel mode +G to strip "bad words".


badword <type> {
	word <text-to-match>;
	replace <replace-with>;
	action <replace|block>;

The badword:: specifies the type, which decides what messages this badword filter applies to. The valid types are:

  • channel: applies to channels with mode +G.
  • message: applies to private messages (not in-channel messages) sent by a user with the +G usermode.
  • all: applies to both channel and message

The badword::word can be a simple word or a regular expression we should search for. The badword::replace is what we should replace this match with. If badword::replace is left out, the word is replaced with <censored>. The badword::action defines what action should be taken if this badword is found. If you specify replace, then the badword is replaced, if you specify block, then the entire message is blocked. If you do not specify a badword::action, replace is assumed.


badword channel {
	word shit;
	replace shoot;