mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-05-30 12:42:27 +00:00
Move filter to separate config and add more scanning (#603)
* Create .gitattributes Added a .gitattributes file that excludes the local customWordFilter.txt file from merged updates, allowing server operators to maintain their own word filter list and not have it overwritten. * Update .gitignore Added chatCensoredList to gitignore * Update .gitignore * Dynamic censor list file changes Removed .gitattributes file, attempted to make chatCensoredList.txt into a dynamic file loaded at runtime instead. * Added additional censorship coverage Censorship now covers: Level titles Level descriptions Reviews Comments * Delete chatCensoredList.txt * Update .gitignore Co-authored-by: Josh <josh@slendy.pw> * Update filter verbiage * Update ProjectLighthouse.Servers.GameServer/Controllers/CommentController.cs Co-authored-by: Josh <josh@slendy.pw> * Update ProjectLighthouse/Helpers/CensorHelper.cs Co-authored-by: Josh <josh@slendy.pw> * Add CensorConfiguration and add more filters Co-authored-by: Josh <josh@slendy.pw>
This commit is contained in:
parent
850cfcefb3
commit
326b9e5529
14 changed files with 70 additions and 53 deletions
|
@ -69,7 +69,9 @@ public class SlotPageController : ControllerBase
|
|||
return this.Redirect("~/slot/" + id);
|
||||
}
|
||||
|
||||
// Prevent potential xml injection and censor content
|
||||
msg = SanitizationHelper.SanitizeString(msg);
|
||||
msg = CensorHelper.FilterMessage(msg);
|
||||
|
||||
await this.database.PostComment(token.UserId, id, CommentType.Level, msg);
|
||||
Logger.Success($"Posted comment from {token.UserId}: \"{msg}\" on user {id}", LogArea.Comments);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue