From 02123f903612d1050194ee243ffb82c047c1edfd Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Fri, 18 May 2007 23:46:14 +0000 Subject: Added bool requirePublic to gridserver. Disabled by default. --- OpenGridServices.GridServer/GridManager.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'OpenGridServices.GridServer') diff --git a/OpenGridServices.GridServer/GridManager.cs b/OpenGridServices.GridServer/GridManager.cs index 1fc7c31..8cf707a 100644 --- a/OpenGridServices.GridServer/GridManager.cs +++ b/OpenGridServices.GridServer/GridManager.cs @@ -383,7 +383,9 @@ namespace OpenGridServices.GridServer TheSim.serverURI = "http://" + TheSim.serverIP + ":" + TheSim.serverPort + "/"; - if (TheSim.serverIP.StartsWith("172.16") || TheSim.serverIP.StartsWith("192.168") || TheSim.serverIP.StartsWith("10.") || TheSim.serverIP.StartsWith("0.") || TheSim.serverIP.StartsWith("255.")) + bool requirePublic = false; + + if (requirePublic && (TheSim.serverIP.StartsWith("172.16") || TheSim.serverIP.StartsWith("192.168") || TheSim.serverIP.StartsWith("10.") || TheSim.serverIP.StartsWith("0.") || TheSim.serverIP.StartsWith("255."))) { return "ERROR! Servers must register with public addresses."; } -- cgit v1.1