mirror of
https://github.com/ayunami2000/ayungee.git
synced 2024-11-09 06:36:05 -08:00
add config option to disable /server
This commit is contained in:
parent
af9af3bbe7
commit
b5cf14b204
|
@ -19,6 +19,8 @@ public class ChatHandler {
|
|||
case "server":
|
||||
if (!client.authed) return false;
|
||||
|
||||
if (!Main.serverCmd) return false;
|
||||
|
||||
if (args.isEmpty()) {
|
||||
//usage msg
|
||||
client.conn.send(new byte[] { 3, 0, 25, 0, (byte) 167, 0, 57, 0, 85, 0, 115, 0, 97, 0, 103, 0, 101, 0, 58, 0, 32, 0, 47, 0, 115, 0, 101, 0, 114, 0, 118, 0, 101, 0, 114, 0, 32, 0, 60, 0, 110, 0, 117, 0, 109, 0, 98, 0, 101, 0, 114, 0, 62 });
|
||||
|
|
|
@ -24,7 +24,7 @@ public class Main {
|
|||
|
||||
public static boolean forwarded = false;
|
||||
|
||||
public static boolean filterUsernames = true;
|
||||
public static boolean serverCmd = true;
|
||||
|
||||
public static boolean useAuth = false;
|
||||
public static int authIpLimit = -1;
|
||||
|
@ -132,6 +132,7 @@ public class Main {
|
|||
|
||||
webPort = (int) config.getOrDefault("web_port", 25565);
|
||||
forwarded = (boolean) config.getOrDefault("forwarded", false);
|
||||
serverCmd = (boolean) config.getOrDefault("server_cmd", true);
|
||||
|
||||
List<String> defaultMotd = new ArrayList<>();
|
||||
|
||||
|
|
|
@ -11,6 +11,8 @@ origin_blacklist: "https://g.eags.us/eaglercraft/origin_blacklist.txt"
|
|||
# for example,
|
||||
# - "https://g.eags.us"
|
||||
origins: []
|
||||
# enable /server command?
|
||||
server_cmd: true
|
||||
# authentication info
|
||||
auth:
|
||||
# use auth
|
||||
|
|
Binary file not shown.
Loading…
Reference in New Issue
Block a user