diff --git a/MCGalaxy/Server/Authentication/LoginAuthenticator.cs b/MCGalaxy/Server/Authentication/LoginAuthenticator.cs index a04d89ed2..feabe90b3 100644 --- a/MCGalaxy/Server/Authentication/LoginAuthenticator.cs +++ b/MCGalaxy/Server/Authentication/LoginAuthenticator.cs @@ -43,7 +43,7 @@ public static bool VerifyLogin(Player p, string mppass) { if (auth.Verify(p, mppass)) return true; } - return !Server.Config.VerifyNames || IPUtil.IsPrivate(p.IP); + return !Server.Config.VerifyNames || (IPUtil.IsPrivate(p.IP) && !Server.Config.VerifyLanIPs); } } diff --git a/MCGalaxy/Server/ServerConfig.cs b/MCGalaxy/Server/ServerConfig.cs index 67be9fe4d..507645149 100644 --- a/MCGalaxy/Server/ServerConfig.cs +++ b/MCGalaxy/Server/ServerConfig.cs @@ -160,6 +160,8 @@ public sealed class ServerConfig : EnvConfig public List DisabledModules = new List(); [ConfigTimespan("death-invulnerability-cooldown", "Other", 2, false)] public TimeSpan DeathCooldown = TimeSpan.FromSeconds(2); + [ConfigBool("verify-lan-ips", "Other", false)] + public bool VerifyLanIPs = false; [ConfigBool("irc", "IRC bot", false)] public bool UseIRC = false;