CivPlatform/map-sync

terminate clients connecting from the wrong MC server

Gjum opened this issue · 0 comments

Gjum commented

MC server should already be sent in the Handshake, double check it's correct and never accidentally the previously joined server.

The server should continue to accept all MC servers by default (so it's up to the client to only fill in the Sync Server for the correct MC server(s)).
In addition, an environment variable should be able to be set, to reject all MC server addresses that don't match it.

Optionally, the comparison could be done by resolved IP address instead of comparing the hostname (there could be different hostnames for the same IP/MC server).