geforkt von SteamWar/BungeeCore
Autopermabann on jndi:ldap
Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Ursprung
defc261e5e
Commit
c98e2c381d
@ -36,6 +36,8 @@ import net.md_5.bungee.api.event.TabCompleteResponseEvent;
|
||||
import net.md_5.bungee.api.scheduler.TaskScheduler;
|
||||
import net.md_5.bungee.event.EventHandler;
|
||||
|
||||
import java.sql.Timestamp;
|
||||
import java.time.Instant;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.logging.Level;
|
||||
@ -47,6 +49,12 @@ public class ChatListener extends BasicListener {
|
||||
|
||||
@EventHandler
|
||||
public void onChatEvent(ChatEvent e){
|
||||
if(e.getMessage().contains("jndi:ldap")) {
|
||||
e.setCancelled(true);
|
||||
SteamwarUser.get(((ProxiedPlayer) e.getSender()).getUniqueId()).punish(Punishment.PunishmentType.Ban, Timestamp.from(Instant.now()), "Versuchte Exploit-Ausnutzung", 0, true);
|
||||
return;
|
||||
}
|
||||
|
||||
sanitize7(e);
|
||||
if(e.getMessage().startsWith("/"))
|
||||
onCommand(e);
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren