3 Commits

Author SHA1 Message Date
893f99c3e5 2.8.9
Bugfix: If the plugin was already converted to T2C-CommandGUI but still a plugin folder named CommandGUI was present, the original folder was overwritten.
Bugfix: If T2CodeLib was not installed, an unwanted error occurred
Bugfix: The permission 'commandgui.updatemsg' was wrongly registered as 'commandgui.updatemsgupdatemsg' and thus also recognized by Luckperm.
2022-07-29 15:16:52 +02:00
JaTiTV
16e6af2fd4 „README.md“ ändern 2022-07-27 20:41:34 +02:00
fa1af88777 2.8.8
This update fixes a security vulnerability where players with modified clients could intercept all commands.
This bug affects the proxy (Bungee, Waterfall etc.)!
2022-07-19 18:25:48 +02:00
8 changed files with 10 additions and 23 deletions

View File

@@ -6,7 +6,7 @@
<groupId>net.t2code</groupId>
<artifactId>CommandGUI_V2</artifactId>
<version>2.8.7</version>
<version>2.8.9</version>
<packaging>jar</packaging>
<name>CommandGUI</name>

View File

@@ -16,7 +16,7 @@ public class BListener implements Listener {
@EventHandler
public void onPluginmessage(PluginMessageEvent event) {
if (event.getTag().equalsIgnoreCase("cgui:bungee")) {
event.setCancelled(true);
DataInputStream stream = new DataInputStream(new ByteArrayInputStream(event.getData()));
try {
String channel = stream.readUTF();
@@ -41,25 +41,12 @@ public class BListener implements Listener {
public void onJoin(PostLoginEvent e) {
ProxiedPlayer player = e.getPlayer();
sendToSpigotPlayer(player.getName(), true);
/*
if (BMySQL.Enable) {
BMySQL.query("INSERT INTO `gui-bungeeplayer` (`UUID`, `Name`, `Online`) VALUES ('" + player.getUniqueId() + "', '" + player.getName()
+ "', 'true') ON DUPLICATE KEY UPDATE `Name` = '" + player.getName() + "', `Online` = 'true';");
}
*/
}
@EventHandler
public void onDisconnect(PlayerDisconnectEvent e) {
ProxiedPlayer player = e.getPlayer();
sendToSpigotPlayer(e.getPlayer().getName(), false);
/*
if (BMySQL.Enable) {
BMySQL.query("INSERT INTO `gui-bungeeplayer` (`UUID`, `Name`, `Online`) VALUES ('" + player.getUniqueId() + "', '" + player.getName()
+ "', 'true') ON DUPLICATE KEY UPDATE `Name` = '" + player.getName() + "', `Online` = 'false';");
}
*/
}
public static void sendToSpigotPlayer(String name, Boolean join) {

View File

@@ -52,10 +52,11 @@ public final class Main extends JavaPlugin {
plugin = this;
autor = this.getDescription().getAuthors();
version = this.getDescription().getVersion();
if (pluginNotFound("T2CodeLib", 96388, Util.getRequiredT2CodeLibVersion())) return;
if (MCVersion.minecraft1_8 || MCVersion.minecraft1_9 || MCVersion.minecraft1_10 || MCVersion.minecraft1_11 || MCVersion.minecraft1_12 || MCVersion.minecraft1_13 || MCVersion.minecraft1_14 || MCVersion.minecraft1_15 || NMSVersion.v1_16_R1) {
legacy = true;
}
if (pluginNotFound("T2CodeLib", 96388, Util.getRequiredT2CodeLibVersion())) return;
if (PluginCheck.pluginCheck("CommandGUI")) {
send.error(this, "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
send.error(this, "");

View File

@@ -17,7 +17,7 @@ import java.util.List;
public class ConfigConverterUnderV5 {
public static void renameMainFolder() {
if (new File("plugins/CommandGUI").exists()) {
if (new File("plugins/CommandGUI").exists() && !Main.getPath().exists()) {
File oldF = new File("plugins/CommandGUI");
File newF = new File("plugins/T2C-CommandGUI");

View File

@@ -42,7 +42,6 @@ public class GUIListener implements Listener {
@EventHandler
public void onInventoryClick(InventoryClickEvent e) {
Player player = (Player) e.getWhoClicked();
JavaPlugin plugin = Main.getPlugin();
if (e.getInventory() == null) return;
if (e.getCurrentItem() == null) return;
for (Gui gui : Main.guiHashMap.values()) {

View File

@@ -18,7 +18,7 @@ public class Permissions {
public static final String useitem = key + "useitem";
public static final String getGuiItemAtLogin = key + "get.guiitem.at.login";
public static final String giveItemOther = key + "giveitem.other";
public static final String updatemsg = key + "updatemsgupdatemsg";
public static final String updatemsg = key + "updatemsg";
public static final String player = key + "player";
public static final String admin = key + "admin";

View File

@@ -4,7 +4,7 @@ main: de.jatitv.commandguiv2.Spigot.Main
api-version: 1.13
prefix: T2C-CommandGUI
authors: [ JaTiTV ]
depend:
softdepend:
- T2CodeLib
commands:

View File

@@ -54,4 +54,4 @@ Optional:
---
<img src="https://bstats.org/signatures/bukkit/CGUI.svg" width="600">
<img src="https://i.imgur.com/tVLZGZg.png" width="600">
<img src="https://i.imgur.com/HoZSt7c.png" width="600">