me1312 / vanillacord Goto Github PK
View Code? Open in Web Editor NEWVanillaCord – IP Forwarding support for Vanilla Minecraft Servers
License: Mozilla Public License 2.0
VanillaCord – IP Forwarding support for Vanilla Minecraft Servers
License: Mozilla Public License 2.0
Gives:
19:53:02 [SEVERE] [mattbojh] <-> ServerConnector [lobby] - encountered exception java.lang.IllegalArgumentException: Unexpected packet received during server login process! 1bb9017b227472616e736c617465223a22646973636f6e6e6563742e67656e65726963526561736f6e222c2277697468223a5b22496e7465726e616c20457863
when connecting
When attempting to connect via a BungeeCord proxy, the following kick message is returned:
disconnected with: Kicked whilst connecting to lobby: Internal Exception: java.lang.VerifyError: Bad type on operand stack
Exception Details:
Location:
aeq.a(Lxp;)V @33: invokestatic
Reason:
Type integer (current frame, stack[0]) is not assignable to 'java/lang/String'
Current Frame:
bci: @33
flags: { }
locals: { 'aeq', 'xp' }
stack: { integer }
There is more, but this was sufficient to track down the cause. In 1.18.2, an extra validation call is made to make sure no invalid characters are in the player's username.
1.18.1
public void a(xd $$0) {
Validate.validState((this.h == aec$a.a ? 1 : 0) != 0, (String)"Unexpected hello packet", (Object[])new Object[0]);
this.j = $$0.b();
if (this.g.U() && !this.a.d()) {
this.h = aec$a.b;
this.a.a((qr)new wy("", this.g.L().getPublic().getEncoded(), this.f));
} else {
this.h = aec$a.e;
}
}
1.18.2
public void a(final xp $$0) {
Validate.validState(this.h == aeq.a.a, "Unexpected hello packet", new Object[0]);
this.j = $$0.b();
Validate.validState(a(this.j.getName()), "Invalid characters in username", new Object[0]);
if (this.g.U() && !this.a.d()) {
this.h = aeq.a.b;
this.a.a((rc)new xk("", this.g.L().getPublic().getEncoded(), this.f));
}
else {
this.h = aeq.a.e;
}
}
I suspect that the patcher is finding the second Validate and making changes to it.
Everything's in the title. (I said "instead" but having both option available when patching the jar would be nice) Would it be possible?
Some users couldn't connect to vanilla server via Bungee due to such errors:
Vanilla error - https://pastebin.com/nXCxeL4p
Bungee error - https://pastebin.com/vmDHpqtb
at the same time some others can...
Bungee with Spigot as Lobby and Vanilla sub-server with ip forwarding is on
idk, possible related issue SpigotMC/BungeeCord#2518
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
Exception in thread "main" java.lang.ExceptionInInitializerError
Caused by: java.lang.UnsupportedOperationException: No class provided, and an appropriate one cannot be found.
at org.apache.logging.log4j.LogManager.callerClass(LogManager.java:573)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:598)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:585)
at net.minecraft.server.Main.(SourceFile:60)
My Version:1.17.1
root@5350:/home/twix/vanillacord# java -jar VanillaCord.jar 1.14.2
VanillaCord launcher v1.6
Searching versions
Reusing patches from branch 1.12
Loading
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at net.ME1312.VanillaCordLauncher.Launch.main(Launch.java:90)
Caused by: java.lang.NullPointerException
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:153)
at uk.co.thinkofdeath.vanillacord.Main.main(Main.java:90)
... 5 more
1.14.0 and 1.14.1 build as intended but not way to build 1.14.2.
Is Mojang guilty in this issue?
Hello again!
I've setup my bungeecord with the latest avaialble build, plus the latest available viaversion build (I know I shouldnt need it, but the protocol doesnt seem to be natively supported by bungeecord). I'm getting the error multiplayer.disconnect.incompatible upon connecting. I'm not sure if this is caused by bungeecord or vanillacord :).
I can't see any messages on my vanillacord server upon connecting, but on my bungeecord server I get:
[19:33:32 INFO]: [/xxx:55056] <-> InitialHandler has connected
[19:33:33 INFO]: [quiquelhappy|/xxx:55056] <-> ServerConnector [simply] has connected
[19:33:33 INFO]: [quiquelhappy] disconnected with: Kicked whilst connecting to simply: multiplayer.disconnect.incompatible
[19:33:33 WARN]: [quiquelhappy|/xxx:55056] <-> ServerConnector [simply] - NativeIoException: readAddress(..) failed: Connection reset by peer
[19:33:33 INFO]: [/xxx:55056|quiquelhappy] -> UpstreamBridge has disconnected
[19:33:33 INFO]: [quiquelhappy|/xxx:55056] <-> ServerConnector [simply] has disconnected
Im sorry to bug you if this is a bungeecord-related issue, just wanted to make sure Im setting up everything correctly. ip forwarding is enabled on my bungeecord server, my bungeecord server and subservers are set with online-mode = true.
Running java -jar VanillaCord.jar 21w39a results in a crash
$ java -jar VanillaCord.jar 21w39a
VanillaCord 1.7
Searching versions
Downloading Minecraft Server 21w39a
Loading
Exception in thread "main" java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:78)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:567)
at uk.co.thinkofdeath.vanillacord.Launch.main(Launch.java:55)
Caused by: java.lang.NullPointerException: Cannot read the array length because "classFile" is null
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:163)
at uk.co.thinkofdeath.vanillacord.Main.main(Main.java:99)
... 5 more
Perhaps, but the MinecraftServer mechanism has changed significantly since 21w39a.
If you start 21w39a as is, you will see the following directory structure.
root/
┠ libraries/
┃┗ mojang
┃ ┗ authlib
┃ ┗ 3.1.36
┃ ┗ authlib-3.1.36.jar
┃ etc...
┃ etc...
┠ versions
┃ ┗ 21w39a
┃ ┗ server-21w39a.jar
┠ logs/
┠ 21w39a.jar
┠ eula.txt
┗ server.properties
With the new update 21w19a it doesn't patch anymore likely due to the new java 16 requirement.
Cuz the new update (21w19a)
VanillaCord branch 1.12
Searching versions
Downloading Minecraft Server 21w19a
Loading
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at uk.co.thinkofdeath.vanillacord.Launch.main(Launch.java:52)
Caused by: java.lang.IllegalArgumentException
at org.objectweb.asm.ClassReader.(ClassReader.java:170)
at org.objectweb.asm.ClassReader.(ClassReader.java:153)
at uk.co.thinkofdeath.vanillacord.Main.main(Main.java:66)
... 5 more
can i get some help?
i dont understand how to use it
Starting server...
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
Loading libraries, please wait...
java.lang.ExceptionInInitializerError
at org.bukkit.craftbukkit.Main.main(Main.java:187)
Caused by: java.lang.UnsupportedOperationException: No class provided, and an appropriate one cannot be found.
at org.apache.logging.log4j.LogManager.callerClass(LogManager.java:573)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:598)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:585)
at net.minecraft.server.v1_8_R3.MinecraftServer.(Unknown Source)
... 1 more
Here you can write about what happened that shouldn't have. If you have any errors in your console related to what happened, you should also paste those here.
Time: 2024-06-21 14:50:25
Description: Exception in server tick loop
java.lang.IllegalAccessError: class vanillacord.translation.NamespacedKey tried to access private method 'void akr.<init>(java.lang.String, java.lang.String)' (vanillacord.translation.NamespacedKey and akr are in unnamed module of loader java.net.URLClassLoader @4ccabbaa)
at vanillacord.translation.NamespacedKey.new(Unknown Source)
at vanillacord.server.VelocityHelper.<clinit>(VelocityHelper.java:29)
at java.base/java.lang.invoke.DirectMethodHandle.allocateInstance(DirectMethodHandle.java:500)
at vanillacord.server.VanillaCord.<clinit>(VanillaCord.java:86)
at apn.e(SourceFile:121)
at net.minecraft.server.MinecraftServer.y(SourceFile:664)
at net.minecraft.server.MinecraftServer.a(SourceFile:281)
at java.base/java.lang.Thread.run(Thread.java:1570)
Here you can provide any extra details you may think useful for solving the problem.
Not sure whether bug or not:
I'm hosting two minecraft vanilla servers (raspi pi5) behind velocity proxy (pi4b) for my kids. On 1.20.4 with whitelists in place everything went well and smoothly.
After updating both servers to 1.20.5 I am unable to connect. I am stuck on "joining world" until a timeout happens, regardless if I'm whitelisted or whitelist is disabled at all.
[02:04:33 INFO]: [connected player] [Player Name] (/[IP]:[Port]) has connected
[02:04:33 INFO]: [server connection] [Player Name] -> [MC-Server] has connected
[02:05:03 INFO]: [connected player] [Player Name] (/[IP]:[Port]) has disconnected
[02:05:03 INFO]: [server connection] [Player Name] -> [MC-Server] has disconnected
[02:05:03] [Server thread/INFO]: com.mojang.authlib.GameProfile@[Profile Guid],name=[Player Name],properties={textures=[Property[name=textures, value=[some key], signature=[some other key]] lost connection: Disconnected
Any advice would behighly appreciated.
Cheers,
Michael
Current velocity settings work flawlessly with minecraft server 1.20.4 vanila Cord.
Using VanillaCord build 22w24b
VanillaCord 1.8
Searching versions
Downloading Minecraft Server 1.20.2
Running the self-extracting server bundle
Loading server bytecode
Found the handshake listener in alq.class
Found the login listener in alr.class
Patching classes
java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)
at uk.co.thinkofdeath.vanillacord.packager.BEv1.edit(BEv1.java:97)
at uk.co.thinkofdeath.vanillacord.packager.BundleEditor.main(BundleEditor.java:59)
at net.minecraft.bundler.Main.lambda$run$0(Main.java:54)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: java.lang.IllegalStateException: Inject failed
at uk.co.thinkofdeath.vanillacord.patcher.LoginListener$1.visitEnd(LoginListener.java:143)
at org.objectweb.asm.ClassReader.readMethod(ClassReader.java:1518)
at org.objectweb.asm.ClassReader.accept(ClassReader.java:744)
at org.objectweb.asm.ClassReader.accept(ClassReader.java:424)
at uk.co.thinkofdeath.vanillacord.patcher.Patcher.patch(Patcher.java:146)
... 8 more
In 1.20.2 the method now accepts a String
instead of a GameProfile
.
1.20.1
protected GameProfile a(final GameProfile $$0) {
final UUID $$ = hy.a($$0.getName());
return new GameProfile($$, $$0.getName());
}
1.20.2
protected static GameProfile b(final String $$0) {
final UUID $$ = hx.a($$0);
return new GameProfile($$, $$0);
}
I should be able to log into a 1.19 server served by the jar generated by VanillaCord through the latest BungeeCord (build 1644)
The VanillaCord server logs no errors.
Client and BungeeCord server fails the connection with logs:
00:35:26 [INFO] [<User>] disconnected with: Kicked whilst connecting to <server_name>: Internal Exception: java.lang.VerifyError: Bad type on operand stack
Exception Details:
Location:
agj.a(Lzf;)V @131: putfield
Reason:
Type 'agj' (current frame, stack[1]) is not assignable to 'com/mojang/authlib/GameProfile'
Current Frame:
bci: @131
flags: { }
locals: { 'agj', 'zf', 'com/mojang/authlib/GameProfile' }
stack: { 'com/mojang/authlib/GameProfile', 'agj' }
Bytecode:
0000000: 2ab4 004a b200 48a6 0007 04a7 0004 0313
0000010: 0139 03bd 0004 b801 3f2b b601 41b8 0144
0000020: 1301 4603 bd00 04b8 013f 2a2b 2ab4 004e
0000030: b601 4a2a b400 4eb6 014d b801 4fb5 00e7
0000040: a700 274d b200 922c b601 522c b601 56b9
0000050: 00b1 0300 2ab4 0050 b600 c69a 000c 2a2c
0000060: b601 59b6 008d b12a b400 4eb6 015d 4d2c
0000070: c600 1a2b b601 412c b601 60b6 0163 9900
0000080: 0c2c 2ab5 0071 b500 4ab1 2abb 0073 5901
0000090: 2b03 b701 66b5 0071 2ab4 004e b601 6999
00000a0: 003a 2ab4 0050 b600 c69a 0030 2ab2 016b
00000b0: b500 4a2a b400 50bb 016d 5912 3d2a b400
00000c0: 4eb6 0171 b601 77b9 017d 0100 2ab4 005f
00000d0: b701 80b6 00a9 a700 0a2a b200 65b5 004a
00000e0: b1
Exception Handler Table:
bci [42, 64] => handler: 67
Stackmap Table:
same_frame(@14)
same_locals_1_stack_item_frame(@15,Integer)
same_locals_1_stack_item_frame(@67,Object[#9])
same_frame(@103)
append_frame(@138,Object[#115])
same_locals_1_stack_item_extended(@217,Object[#2])
same_locals_1_stack_item_frame(@224,Object[#2])
00:35:26 [INFO] [<User>] -> UpstreamBridge has disconnected
00:35:26 [INFO] [<User>] <-> ServerConnector [<server_name>] has disconnected
ip_forward: true
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
Exception in thread "main" java.lang.ExceptionInInitializerError
Caused by: java.lang.UnsupportedOperationException: No class provided, and an appropriate one cannot be found.
at org.apache.logging.log4j.LogManager.callerClass(LogManager.java:573)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:598)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:585)
at net.minecraft.server.Main.(SourceFile:60)
My Version:1.17.1
Running java -jar VanillaCord.jar 1.16.4
(or the latest snapshot, 20w45a) results in a crash
VanillaCord launcher v1.6
Searching versions
Reusing patches from branch 1.12
Loading
Found the login listener in aba.class
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at net.ME1312.VanillaCordLauncher.Launch.main(Launch.java:90)
Caused by: java.lang.NullPointerException
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:153)
at uk.co.thinkofdeath.vanillacord.Main.main(Main.java:90)
... 5 more
This does not happen with 1.16.3 or other previous versions.
Hi there! Currently this repository has no clear license, and without that GitHub's terms of service state we legally cannot modify the code of this repository in any way, even locally or in a fork: https://docs.github.com/en/free-pro-team@latest/github/creating-cloning-and-archiving-repositories/licensing-a-repository#choosing-the-right-license
For context, I'm interested in tinkering with this in a private GitHub organisation, though the repo would remain private and not be distributed. Other people may like to know the clear terms of how, if at all, we may use this code. Would you consider adding a license to let us know whether this is possible?
No clear license means we do not have the rights to do more than look at the code :)
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
Exception in thread "main" java.lang.ExceptionInInitializerError
Caused by: java.lang.UnsupportedOperationException: No class provided, and an appropriate one cannot be found.
at org.apache.logging.log4j.LogManager.callerClass(LogManager.java:573)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:598)
at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:585)
at net.minecraft.server.Main.(SourceFile:60)
My Version:1.17.1
I have attempted to build and run a snapshot as a test (latest 21w37a). I see in your notes you say added support for velocity ip-forwarding. Does this mean this now only supports velocity? I hooked mine to bungee and waterfall to run some tests and it shows nothing in the log on the snapshot server when attempting the connection.
hi
When starting server 1.15 with this startup parameter: java -Xms128M -Xmx1024M -jar VanillaCord.jar, I get an error that causes the server to crash, it is as follows: / home / container $ java -Xms128M -Xmx1024M -jar VanillaCord .jar
Args: , I would like to know how to fix it.
Is it possible to add support for velocity modern forwarding?
The snapshot server is down
executing java -jar VanillaCord.jar 1.18-pre1
results in:
VanillaCord 1.8
Searching versions
Found Minecraft Server 1.18-pre1
Running the self-extracting server bundle
Cannot locate server file, giving up
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.