aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services
diff options
context:
space:
mode:
authorDiva Canto2012-11-07 19:59:54 -0800
committerDiva Canto2012-11-07 19:59:54 -0800
commiteb273b808ee9723ff386729b0f19e5770ef86af4 (patch)
tree846e77059874ee36680ff4ba98d7abaf2ca857a5 /OpenSim/Services
parentChange user message on TeskInventoryAccepted to let the viewer format it (diff)
downloadopensim-SC_OLD-eb273b808ee9723ff386729b0f19e5770ef86af4.zip
opensim-SC_OLD-eb273b808ee9723ff386729b0f19e5770ef86af4.tar.gz
opensim-SC_OLD-eb273b808ee9723ff386729b0f19e5770ef86af4.tar.bz2
opensim-SC_OLD-eb273b808ee9723ff386729b0f19e5770ef86af4.tar.xz
HG: Hopefully this fixes the issues with port 80 once and for all.
Diffstat (limited to 'OpenSim/Services')
-rw-r--r--OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs2
-rw-r--r--OpenSim/Services/HypergridService/GatekeeperService.cs23
2 files changed, 23 insertions, 2 deletions
diff --git a/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs b/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs
index 19dffc3..5bcff48 100644
--- a/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs
@@ -321,7 +321,7 @@ namespace OpenSim.Services.Connectors.Hypergrid
321 args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); 321 args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString());
322 args["teleport_flags"] = OSD.FromString(flags.ToString()); 322 args["teleport_flags"] = OSD.FromString(flags.ToString());
323 323
324 OSDMap result = WebUtil.PostToService(uri, args, 20000); 324 OSDMap result = WebUtil.PostToService(uri, args, 80000);
325 if (result["Success"].AsBoolean()) 325 if (result["Success"].AsBoolean())
326 { 326 {
327 OSDMap unpacked = (OSDMap)result["_Result"]; 327 OSDMap unpacked = (OSDMap)result["_Result"];
diff --git a/OpenSim/Services/HypergridService/GatekeeperService.cs b/OpenSim/Services/HypergridService/GatekeeperService.cs
index 004311f..7b84d55 100644
--- a/OpenSim/Services/HypergridService/GatekeeperService.cs
+++ b/OpenSim/Services/HypergridService/GatekeeperService.cs
@@ -68,6 +68,7 @@ namespace OpenSim.Services.HypergridService
68 private static UUID m_ScopeID; 68 private static UUID m_ScopeID;
69 private static bool m_AllowTeleportsToAnyRegion; 69 private static bool m_AllowTeleportsToAnyRegion;
70 private static string m_ExternalName; 70 private static string m_ExternalName;
71 private static Uri m_Uri;
71 private static GridRegion m_DefaultGatewayRegion; 72 private static GridRegion m_DefaultGatewayRegion;
72 73
73 public GatekeeperService(IConfigSource config, ISimulationService simService) 74 public GatekeeperService(IConfigSource config, ISimulationService simService)
@@ -99,6 +100,15 @@ namespace OpenSim.Services.HypergridService
99 if (m_ExternalName != string.Empty && !m_ExternalName.EndsWith("/")) 100 if (m_ExternalName != string.Empty && !m_ExternalName.EndsWith("/"))
100 m_ExternalName = m_ExternalName + "/"; 101 m_ExternalName = m_ExternalName + "/";
101 102
103 try
104 {
105 m_Uri = new Uri(m_ExternalName);
106 }
107 catch
108 {
109 m_log.WarnFormat("[GATEKEEPER SERVICE]: Malformed gatekeeper address {0}", m_ExternalName);
110 }
111
102 Object[] args = new Object[] { config }; 112 Object[] args = new Object[] { config };
103 m_GridService = ServerUtils.LoadPlugin<IGridService>(gridService, args); 113 m_GridService = ServerUtils.LoadPlugin<IGridService>(gridService, args);
104 m_PresenceService = ServerUtils.LoadPlugin<IPresenceService>(presenceService, args); 114 m_PresenceService = ServerUtils.LoadPlugin<IPresenceService>(presenceService, args);
@@ -433,7 +443,18 @@ namespace OpenSim.Services.HypergridService
433 string externalname = m_ExternalName.TrimEnd(trailing_slash); 443 string externalname = m_ExternalName.TrimEnd(trailing_slash);
434 m_log.DebugFormat("[GATEKEEPER SERVICE]: Verifying {0} against {1}", addressee, externalname); 444 m_log.DebugFormat("[GATEKEEPER SERVICE]: Verifying {0} against {1}", addressee, externalname);
435 445
436 return string.Equals(addressee, externalname, StringComparison.OrdinalIgnoreCase); 446 Uri uri;
447 try
448 {
449 uri = new Uri(addressee);
450 }
451 catch
452 {
453 m_log.DebugFormat("[GATEKEEPER SERVICE]: Visitor provided malformed service address {0}", addressee);
454 return false;
455 }
456
457 return string.Equals(uri.GetLeftPart(UriPartial.Authority), m_Uri.GetLeftPart(UriPartial.Authority), StringComparison.OrdinalIgnoreCase) ;
437 } 458 }
438 459
439 #endregion 460 #endregion