diff --git a/OpenSim/Framework/Communications/UserManagerBase.cs b/OpenSim/Framework/Communications/UserManagerBase.cs index ef900ead84..fd02382896 100644 --- a/OpenSim/Framework/Communications/UserManagerBase.cs +++ b/OpenSim/Framework/Communications/UserManagerBase.cs @@ -28,6 +28,7 @@ using System; using System.Collections; using System.Collections.Generic; +using System.Net; using System.Reflection; using System.Security.Cryptography; using libsecondlife; @@ -362,6 +363,13 @@ namespace OpenSim.Framework.Communications // User connection agent.AgentOnline = true; + if (request.Params.Count > 1) + { + IPEndPoint RemoteIPEndPoint = (IPEndPoint)request.Params[1]; + agent.AgentIP = RemoteIPEndPoint.Address.ToString(); + agent.AgentPort = (uint)RemoteIPEndPoint.Port; + } + // Generate sessions RNGCryptoServiceProvider rand = new RNGCryptoServiceProvider(); byte[] randDataS = new byte[16]; diff --git a/OpenSim/Framework/Servers/BaseHttpServer.cs b/OpenSim/Framework/Servers/BaseHttpServer.cs index c3bd0855e3..23c28e6328 100644 --- a/OpenSim/Framework/Servers/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/BaseHttpServer.cs @@ -380,6 +380,7 @@ namespace OpenSim.Framework.Servers string methodName = xmlRprcRequest.MethodName; if (methodName != null) { + xmlRprcRequest.Params.Add(request.RemoteIPEndPoint); XmlRpcResponse xmlRpcResponse; XmlRpcMethod method;