mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-01 04:31:58 +01:00
22 lines
1.5 KiB
Diff
22 lines
1.5 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: 0x22 <0x22@futureclient.net>
|
|
Date: Thu, 26 Apr 2018 04:41:11 -0400
|
|
Subject: [PATCH] Fix exploit that allowed colored signs to be created
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
index 0240221d4415df8ac8cbcf2fd0c4118d97500620..8980f0187d0e236ae115317199619fc9f4e69745 100644
|
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
@@ -2790,9 +2790,9 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser
|
|
TextFilter.FilteredText currentLine = signText.get(i);
|
|
|
|
if (this.player.isTextFilteringEnabled()) {
|
|
- lines.add(net.kyori.adventure.text.Component.text(currentLine.getFiltered()));
|
|
+ lines.add(net.kyori.adventure.text.Component.text(SharedConstants.filterText(currentLine.getFiltered())));
|
|
} else {
|
|
- lines.add(net.kyori.adventure.text.Component.text(currentLine.getRaw()));
|
|
+ lines.add(net.kyori.adventure.text.Component.text(SharedConstants.filterText(currentLine.getRaw())));
|
|
}
|
|
}
|
|
SignChangeEvent event = new SignChangeEvent((org.bukkit.craftbukkit.block.CraftBlock) player.getWorld().getBlockAt(x, y, z), this.player.getBukkitEntity(), lines);
|