From d943abea579ab9e5f07fb5baac30991415655647 Mon Sep 17 00:00:00 2001 From: Homer Horwitz Date: Thu, 11 Dec 2008 19:52:29 +0000 Subject: Move from IP to hostname for seed caps on login, for gridmode and standalone. All the other caps (except the initial one) are already sent with hostname instead of IP. NOTE: This changes gridserver and userserver --- OpenSim/Data/RegionProfileData.cs | 2 +- OpenSim/Grid/GridServer/GridManager.cs | 1 + OpenSim/Region/Communications/Local/LocalLoginService.cs | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Data/RegionProfileData.cs b/OpenSim/Data/RegionProfileData.cs index 5a3a42c..3759341 100644 --- a/OpenSim/Data/RegionProfileData.cs +++ b/OpenSim/Data/RegionProfileData.cs @@ -161,7 +161,7 @@ namespace OpenSim.Data simData.httpPort = Convert.ToUInt32((string) responseData["http_port"]); simData.remotingPort = Convert.ToUInt32((string) responseData["remoting_port"]); simData.serverURI = (string) responseData["server_uri"]; - simData.httpServerURI = "http://" + simData.serverIP + ":" + simData.httpPort.ToString() + "/"; + simData.httpServerURI = "http://" + (string)responseData["sim_host"] + ":" + simData.httpPort.ToString() + "/"; simData.UUID = new UUID((string) responseData["region_UUID"]); simData.regionName = (string) responseData["region_name"]; } diff --git a/OpenSim/Grid/GridServer/GridManager.cs b/OpenSim/Grid/GridServer/GridManager.cs index c60334b..be3a7cf 100644 --- a/OpenSim/Grid/GridServer/GridManager.cs +++ b/OpenSim/Grid/GridServer/GridManager.cs @@ -810,6 +810,7 @@ namespace OpenSim.Grid.GridServer m_log.Info("[DATA]: found " + (string)simData.regionName + " regionHandle = " + (string)requestData["region_handle"]); responseData["sim_ip"] = Util.GetHostFromDNS(simData.serverIP).ToString(); + responseData["sim_host"] = simData.serverIP; responseData["sim_port"] = simData.serverPort.ToString(); responseData["server_uri"] = simData.serverURI; responseData["http_port"] = simData.httpPort.ToString(); diff --git a/OpenSim/Region/Communications/Local/LocalLoginService.cs b/OpenSim/Region/Communications/Local/LocalLoginService.cs index 50a8e16..7f16ec2 100644 --- a/OpenSim/Region/Communications/Local/LocalLoginService.cs +++ b/OpenSim/Region/Communications/Local/LocalLoginService.cs @@ -309,9 +309,9 @@ namespace OpenSim.Region.Communications.Local seedcap = "https://" + serversInfo.HttpSSLCN + ":" + serversInfo.httpSSLPort + "/CAPS/" + capsPath + "0000/"; } - else + else { - seedcap = "http://" + regionInfo.ExternalEndPoint.Address.ToString() + ":" + serversInfo.HttpListenerPort + "/CAPS/" + capsPath + "0000/"; + seedcap = "http://" + regionInfo.ExternalEndPoint + ":" + serversInfo.HttpListenerPort + "/CAPS/" + capsPath + "0000/"; } response.SeedCapability = seedcap; //regionInfo.ExternalEndPoint.Address.ToString() + ":" + regionInfo.HttpPort + "/CAPS/" + capsPath + "0000/"; -- cgit v1.1