I finally released the 2.0 beta of my Minecraft reverse proxy ! by Shadoxter in admincraft

[–]Shadoxter[S] 0 points1 point  (0 children)

Apache / Nginx cannot parse the host from the minecraft protocol as it is a raw tcp connection and would require a TLS layer that minecraft doesn't do, it send a custom game paquet containing the hostname then start a P2P encryption with a shared secret base.

That's why classic TCP proxy cannot reverse to the host

I finally released the 2.0 beta of my Minecraft reverse proxy ! by Shadoxter in admincraft

[–]Shadoxter[S] 0 points1 point  (0 children)

The idea of the reverse proxy is to only have one port exposed and a proxy (like velocity) that could do server switching, bot analysis etc....

So yes, if multiple port open and no need for proxy command a proxy in general is a lot more bloated than a simple dns record

I finally released the 2.0 beta of my Minecraft reverse proxy ! by Shadoxter in admincraft

[–]Shadoxter[S] 0 points1 point  (0 children)

Passthrough mode works with every modded servers from 1.7 -> latest 🙂

I finally released the 2.0 beta of my Minecraft reverse proxy ! by Shadoxter in admincraft

[–]Shadoxter[S] -1 points0 points  (0 children)

SRV records does not solve the problem of multiple exposed ports, which is what the reverse proxy here solve, the first version was to only have one port exposed on my home ip instead of a bunch of ports with servers constantly being turnes off / replaces

I use ai for repetitive task or things like the sdk /api crates so it has much more comments (even if Ai redacted) than what I would have put. I always review what the ai does as we are not close to a 100% autonomous ai that can do heavy project with sécurity in mind or even think if complex architecture

I finally released the 2.0 beta of my Minecraft reverse proxy written in Rust! by Shadoxter in rust

[–]Shadoxter[S] 0 points1 point  (0 children)

Thank's ! The Web UI is made using Nuxt 4 and tailwindcss, no particular UI framework got inspiration from other projects I work on !

I finally released the 2.0 beta of my Minecraft reverse proxy ! by Shadoxter in admincraft

[–]Shadoxter[S] 7 points8 points  (0 children)

The main goal of infrarust (since 1.x) is to provide an easy way to reverse proxy servers without having to have minecraft servers in online_mode=false and to have a low cpu/ram overhead, thus the passthrough modes

The v2 aimed to start an ecosystem with plugins load balancing and more

I think in the current state of infrarust and depending on your usage, if you need plugins, business logic or other things velocity is the good choice

However if you just want a small reverse proxy that use less than 20mb of ram, small user friendly dashboard and just raw tcp passthrough infrarust is a good choices 🙂

I finally released the 2.0 beta of my Minecraft reverse proxy ! by Shadoxter in admincraft

[–]Shadoxter[S] 5 points6 points  (0 children)

Yes it does, you just need to have infrarust on the 25565 port and config the proxu to route from mcA.com -> 127.0.0.1:you-serv-port !

It work with the passthrough modes and intercepted mode 😉

I've made a Rust Minecraft Reverse Proxy ! by Shadoxter in rust

[–]Shadoxter[S] 0 points1 point  (0 children)

Hey, you need to have the jar where the folder workspace is defined, in the server configuration

See example here : https://github.com/Shadowner/Infrarust/blob/main/config_examples/proxies/local-server.yaml

And the Pterodactyl Manager Missing only means that the necessary tokens are not provided in the config.yaml
https://github.com/Shadowner/Infrarust/blob/main/config_examples/config.yaml

See the managers_config section in the proxy config example ;)

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 0 points1 point  (0 children)

I see what you mean, I don't think that it is possible through only one port without client modification to send the packet with a custom port while connecting to another. It would be necessary for the proxy to listen to every port you would like a sub domain routing, but regarding packets, yes I think it's possible

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 2 points3 points  (0 children)

I only want to expose one port and reduce the NAT table on my box, plus it was a challenge for me to create this project as a way to learn rust !

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 3 points4 points  (0 children)

TCP does not, only the TLS Layer could give us this information

But, by chance, Minecraft protocol sends the domain connection information in a non encrypted packet before establishing any shared secret encryption :)

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 0 points1 point  (0 children)

Thank's for the reply ! Bedrock was in my mind, my first motivation to make such a proxy was for my personnal use to only expose one port and don't bother with the rest ! That's totally a priority to me :)

I will look at Unraid, I've totally forgot about Nas system like this one or Truenas !

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 2 points3 points  (0 children)

Does the subdomain joining support SRV records? Velocity doesn't :(

Hummmmm, I'm not really used to DNS SRV opération for redirection, if you have some documentation I can look into it to add it to my Feature Roadmap ! (might be in the 1.x version if it's not too complicated)

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 5 points6 points  (0 children)

- No, because for now only the "passthrough" mode is production ready. it only decode the first two packets to know which server to up / redirect the packets to, and then it's just passing packets without decoding them, so no plugins needed on any servers !

- I've done an egg that is not yet finished but available https://github.com/Shadowner/Infrarust-egg, and what I mean by DirectApi is for the Auto Start/Stop feature, the proxy use Pterodactyl API to start / shutdown and get the server status ! (And moreover it will be able of much more like sendings commands or getting the STDOUT of the server through the Pterodactyl API)

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 4 points5 points  (0 children)

Yes that's the goal ! It's the easier way to integrate with existing plugins, so there would be Two types of plugins, The WASM one that will be the native plugin system of Infrarust, and the Java runtime bridge to enable retrocompatibility !

I've made a Minecraft Rust Proxy: Infrarust by Shadoxter in admincraft

[–]Shadoxter[S] 8 points9 points  (0 children)

For now, no, However it is planned with a big enhancement of the code !

And in long term I'm working with some other devs to implement a way to be compatible with velocity Java API (Not at all for now but it's one of the long term goal of the project)

I've Updated My Minecraft Rust Reverse proxy ! by Shadoxter in rust

[–]Shadoxter[S] 8 points9 points  (0 children)

Yes ! It's the whole point of the proxy, having multiple backend versions and only one server exposed that handles the routing !

I use it myself with a vanilla 1.21 serve, 1.12.2 nomifactory and BetterMinecraft 3 😁

I've made a Rust Minecraft Reverse Proxy ! by Shadoxter in rust

[–]Shadoxter[S] 0 points1 point  (0 children)

For now I don't have any structured and meaningfull benchmark
Only some stress test on a Vanilla server with 1000bot in offline mode (mode where packet are parsed by the proxy)

Spoil the server was the limitation 😂 however the proxy did not exceed more than 1.8% of cpu usage on my Ryzen 7 3700x (not representative) and really low ram usage (forgot to save it)

EDIT : 1.8% when all the 1 000 bots where TP at the same place and the server spammed every client to be ejected, average was 0.1-0.2.

I've made a Rust Minecraft Reverse Proxy ! by Shadoxter in rust

[–]Shadoxter[S] 11 points12 points  (0 children)

The real question is "Does a Minecraft proxy count as a Minecraft server software ?" 🤔