VerifyAgent() public method

public VerifyAgent ( Aurora.Framework.AgentCircuitData circuit ) : bool
circuit Aurora.Framework.AgentCircuitData
return bool
        protected bool Authenticate(AgentCircuitData aCircuit)
        {
            if (!CheckAddress (aCircuit.ServiceSessionID))
                return false;

            string userURL = string.Empty;
            if (aCircuit.ServiceURLs.ContainsKey ("HomeURI"))
                userURL = aCircuit.ServiceURLs["HomeURI"].ToString ();

            if (userURL == string.Empty)
            {
                MainConsole.Instance.DebugFormat ("[GATEKEEPER SERVICE]: Agent did not provide an authentication server URL");
                return false;
            }

            if (userURL == m_ExternalName)
                return m_UserAgentService.VerifyAgent (aCircuit.SessionID, aCircuit.ServiceSessionID);
            else
            {
                //                Object[] args = new Object[] { userURL };
                IUserAgentService userAgentService = new UserAgentServiceConnector (userURL);
                if (userAgentService != null)
                {
                    try
                    {
                        return userAgentService.VerifyAgent (aCircuit.SessionID, aCircuit.ServiceSessionID);
                    }
                    catch
                    {
                        MainConsole.Instance.DebugFormat ("[GATEKEEPER SERVICE]: Unable to contact authentication service at {0}", userURL);
                        return false;
                    }
                }
            }

            return false;
        }
 public bool VerifyAgent(AgentCircuitData circuit)
 {
     if (circuit.ServiceURLs.ContainsKey ("HomeURI"))
     {
         string url = circuit.ServiceURLs["HomeURI"].ToString ();
         UserAgentServiceConnector security = new UserAgentServiceConnector (url);
         return security.VerifyAgent (circuit.SessionID, circuit.ServiceSessionID);
     }
     else
         MainConsole.Instance.DebugFormat ("[HG ENTITY TRANSFER MODULE]: Agent {0} {1} does not have a HomeURI OH NO!", circuit.firstname, circuit.lastname);
     return VerifyAgent (circuit.SessionID, circuit.ServiceSessionID);
 }