mirror of
https://github.com/opensim/opensim.git
synced 2026-08-10 19:36:07 +08:00
* Excelsior!
This commit is contained in:
@@ -659,12 +659,18 @@ namespace OpenSim.Grid.GridServer
|
||||
TheSim.serverURI = "http://" + TheSim.serverIP + ":" + TheSim.serverPort + "/";
|
||||
|
||||
bool requirePublic = false;
|
||||
bool requireValid = true;
|
||||
|
||||
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.";
|
||||
}
|
||||
|
||||
if (requireValid && (TheSim.serverIP.StartsWith("0.")))
|
||||
{
|
||||
return "ERROR! 0.*.*.* Addresses are invalid, please check your server config and try again";
|
||||
}
|
||||
|
||||
|
||||
try
|
||||
{
|
||||
|
||||
@@ -30,6 +30,7 @@ using System.Collections;
|
||||
using Nwc.XmlRpc;
|
||||
using OpenSim.Framework.Data;
|
||||
using OpenSim.Framework.UserManagement;
|
||||
using OpenSim.Framework.Utilities;
|
||||
|
||||
namespace OpenSim.Grid.UserServer
|
||||
{
|
||||
@@ -63,6 +64,10 @@ namespace OpenSim.Grid.UserServer
|
||||
response.RegionX = SimInfo.regionLocX;
|
||||
response.RegionY = SimInfo.regionLocX;
|
||||
|
||||
//Not sure if the + "/CAPS/" should in fact be +"CAPS/" depending if there is already a / as part of httpServerURI
|
||||
string capsPath = Util.GetRandomCapsPath();
|
||||
response.SeedCapability = SimInfo.httpServerURI + "CAPS/" + capsPath + "0000/";
|
||||
|
||||
// Notify the target of an incoming user
|
||||
Console.WriteLine("Notifying " + SimInfo.regionName + " (" + SimInfo.serverURI+ ")");
|
||||
|
||||
@@ -78,6 +83,7 @@ namespace OpenSim.Grid.UserServer
|
||||
SimParams["startpos_y"] = theUser.currentAgent.currentPos.Y.ToString();
|
||||
SimParams["startpos_z"] = theUser.currentAgent.currentPos.Z.ToString();
|
||||
SimParams["regionhandle"] = theUser.currentAgent.currentHandle.ToString();
|
||||
SimParams["caps_path"] = capsPath;
|
||||
ArrayList SendParams = new ArrayList();
|
||||
SendParams.Add(SimParams);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user