Implement lockdown management in automod system

- Added functionality to activate and deactivate lockdowns via the automod worker, responding to specific job names.
- Enhanced the anti-raid join handler to apply a verification role when lockdown is active and the anti-raid action is set to VERIFY.
- Updated the automod configuration to ensure default rules are created if missing, improving the setup process for new guilds.
- Introduced new API endpoints for managing cases and warnings, allowing for soft deletion and reason updates.
- Enhanced the moderation dashboard to include warnings management, improving user experience in moderation tasks.
- Updated localization files to reflect new features and improve user guidance in both English and German.
This commit is contained in:
smueller
2026-07-24 10:21:49 +02:00
parent fba597a6f2
commit bd1b55fff7
22 changed files with 1517 additions and 242 deletions

View File

@@ -347,34 +347,121 @@
"reason": "Reason",
"reasonPlaceholder": "Optional default reason",
"casesTitle": "Cases",
"casesDescription": "List of the most recent moderation cases (read-only).",
"casesDescription": "View moderation cases, edit the reason, or soft-delete.",
"searchPlaceholder": "Search by user/moderator ID or reason",
"actionPlaceholder": "Filter by action, e.g. BAN",
"casesEmpty": "No cases found.",
"target": "Target",
"moderator": "Moderator",
"createdAt": "Created at",
"noReason": "No reason provided"
"noReason": "No reason provided",
"editReason": "Edit reason",
"saveReason": "Save",
"deleteCase": "Delete case",
"confirmDeleteCase": "Really delete this case?",
"warningsTitle": "Warnings",
"warningsDescription": "Recent warnings. Remove deletes the warning entry.",
"warningsEmpty": "No warnings found.",
"warningsSearchUser": "Filter by user ID",
"removeWarning": "Remove warning",
"confirmRemoveWarning": "Really remove this warning?"
},
"automod": {
"title": "Auto-Moderation",
"description": "Base settings plus anti-raid and anti-nuke protection.",
"description": "Filter rules, anti-raid and anti-nuke for this server.",
"enabledLabel": "Auto-moderation enabled",
"enabledHint": "Enables all auto-moderation rules (spam, word filter, links, …) on this server.",
"enabledHint": "Master switch: only enabled rules below apply when this is on.",
"rulesTitle": "Filter rules",
"rulesDescription": "Per rule: action, thresholds, word/link lists and exceptions.",
"ruleAction": "Action",
"timeoutMinutes": "Timeout (minutes)",
"actions": {
"DELETE": "Delete message",
"WARN": "Warn",
"TIMEOUT": "Timeout",
"KICK": "Kick",
"BAN": "Ban"
},
"thresholds": {
"maxMessages": "Max messages",
"windowSeconds": "Time window (seconds)",
"maxMentions": "Max mentions",
"capsPercent": "Caps ratio (%)",
"minLength": "Min message length",
"maxEmojis": "Max emojis",
"duplicateCount": "Duplicate count"
},
"linkWhitelist": "Link whitelist (hosts)",
"linkBlacklist": "Link blacklist (hosts)",
"addHost": "Add host",
"wordList": "Word list",
"regexList": "Regex patterns",
"wordPlaceholder": "banned word",
"addWord": "Add word",
"addRegex": "Add regex",
"exceptionRoles": "Exception roles",
"exceptionChannels": "Exception channels",
"rules": {
"SPAM": {
"title": "Spam",
"description": "Too many messages in a short time."
},
"MASS_MENTION": {
"title": "Mass mentions",
"description": "Too many @-mentions in one message."
},
"CAPS": {
"title": "Caps",
"description": "Mostly uppercase text."
},
"INVITE_LINK": {
"title": "Invite links",
"description": "Block Discord invite links."
},
"EXTERNAL_LINK": {
"title": "External links",
"description": "Check links against whitelist/blacklist."
},
"WORD_FILTER": {
"title": "Word filter",
"description": "Words and regex patterns."
},
"DUPLICATE": {
"title": "Duplicates",
"description": "Repeated identical messages."
},
"EMOJI_SPAM": {
"title": "Emoji spam",
"description": "Too many emojis in one message."
},
"ZALGO": {
"title": "Zalgo",
"description": "Block zalgo/combining characters."
},
"PHISHING": {
"title": "Phishing",
"description": "Known scam/phishing domains."
}
},
"antiRaidTitle": "Anti-Raid",
"antiRaidDescription": "Detects unusually fast join waves and automatically activates a lockdown.",
"antiRaidDescription": "Detects unusually fast join waves.",
"antiRaidEnabled": "Anti-raid enabled",
"antiRaidJoinThreshold": "Join threshold",
"antiRaidWindowSeconds": "Time window (seconds)",
"antiRaidActionHint": "Currently implemented response: server lockdown.",
"antiRaidAction": "Response",
"antiRaidActions": {
"LOCKDOWN": "Lockdown (lock channels)",
"VERIFY": "Verify (unverified role)"
},
"antiRaidActionHint": "Verify applies the unverified role from the Verification module and continues for new joins until the raid status is cleared.",
"antiNukeTitle": "Anti-Nuke",
"antiNukeDescription": "Protects against mass bans or mass channel deletions by compromised accounts.",
"antiNukeEnabled": "Anti-nuke enabled",
"antiNukeBanThreshold": "Ban threshold",
"antiNukeChannelThreshold": "Channel deletion threshold",
"antiNukeWindowSeconds": "Time window (seconds)",
"lockdownActive": "Lockdown active",
"lockdownActiveHint": "Automatically set when a raid is detected. Toggle off manually to end the lockdown."
"lockdownActive": "Raid response active",
"lockdownActiveHint": "Lockdown: unlock channels when turned off. Verify: only clears the status flag."
},
"logging": {
"title": "Logging",