Rocket.chat: Filter bad/Offensive words from a list

Created on 29 Oct 2015  路  14Comments  路  Source: RocketChat/Rocket.Chat

Hi

I think it's important to have since users can use bad/offensive words it's easy we can have a very good words list from either www.noswearing.com or www.bannedwordlist.com and replace(badword,'**') with stars :)

I can do this ASAP I just need to know where to start thanks :)

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

message improvement

Most helpful comment

@matthijs2704 @xj721386 @mchilson @djeber @MyPod It's DONE
https://github.com/RocketChat/Rocket.Chat/pull/2940

All 14 comments

censoring should probably be an option selectable by the users, with an admin setting for auto-enabling, perhaps. Letting people add custom words would be too something to do - and, in parallel, allow to set words that "ping" users

adding it as an option is easy :)

I have found a good nodejs package

we use right now and have a some code for it:

RocketChat.callbacks.add(beforeSaveMessage, function,(message){
return filter(message.msg);// filter is a function from that package!
},1);

but where can add this ? and how do I deploy it?

Thanks
@MyPod

I have got everything here code and the way to add it but it needs just to be added as an option in the admin panel so user can enable/disable it and/or set a banned list of words in textarea...

It's pretty easy to do but I don't know where should I add it??

any update on this one !!

Yes, I think this is a viable feature also that needs to be included in any chat.

I am just wondering if capensisma have figured out where to actually do the filtering?

@capensisma have you figured out yet how to do this?

@matthijs2704 @xj721386 sorry I was sleeping :D do you want me to do a PR right now for this? I have many contribution on hold lol just lazy :'(

@capensisma whoops did I wake you? But if you can do a PR, yes please! :smile:

@matthijs2704 ok I am Officially awake now :D Thanks

Let's do this! :+1:

It's working :D OMG
lemme send a PR after I clean up the code a little lol :D

@matthijs2704 @xj721386 @mchilson @djeber @MyPod It's DONE
https://github.com/RocketChat/Rocket.Chat/pull/2940

Great job on adding this in, but one problem - I notice it adds a default list of words. Is there any way to flush this ? I've attempted to edit the lang.js file and restarting the server, but entries in that file I've removed still get filtered out.

Closing this due #2940

Was this page helpful?
0 / 5 - 0 ratings

Related issues

engelgabriel picture engelgabriel  路  3Comments

djeber picture djeber  路  3Comments

amayer5125 picture amayer5125  路  3Comments

marceloschmidt picture marceloschmidt  路  3Comments

mddvul22 picture mddvul22  路  3Comments