From 1015ca38636b550500719375168646d741f89db1 Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Tue, 26 Aug 2008 05:41:07 +0000 Subject: * It turns out that Mono doesn't currently support setting the Certificate validation handler, however, it throws a NotImplemented exception. * Added Try/Catch/Message --- OpenSim/Framework/Servers/BaseHttpServer.cs | 7 ++++++- .../Environment/Modules/InterGrid/OpenGridProtocolModule.cs | 9 ++++++++- 2 files changed, 14 insertions(+), 2 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Framework/Servers/BaseHttpServer.cs b/OpenSim/Framework/Servers/BaseHttpServer.cs index 13c5752..303ce64 100644 --- a/OpenSim/Framework/Servers/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/BaseHttpServer.cs @@ -559,7 +559,8 @@ namespace OpenSim.Framework.Servers foreach (string pattern in m_llsdHandlers.Keys) { - if (searchquery.StartsWith(searchquery)) + + if (pattern.StartsWith(searchquery) && searchquery.Length >= pattern.Length) { if (String.IsNullOrEmpty(bestMatch) || searchquery.Length > bestMatch.Length) { @@ -568,6 +569,10 @@ namespace OpenSim.Framework.Servers } } + // extra kicker to remove the default XMLRPC login case.. just in case.. + if (path == "/") + return false; + if (String.IsNullOrEmpty(bestMatch)) { diff --git a/OpenSim/Region/Environment/Modules/InterGrid/OpenGridProtocolModule.cs b/OpenSim/Region/Environment/Modules/InterGrid/OpenGridProtocolModule.cs index 5874d9b..89a01f0 100644 --- a/OpenSim/Region/Environment/Modules/InterGrid/OpenGridProtocolModule.cs +++ b/OpenSim/Region/Environment/Modules/InterGrid/OpenGridProtocolModule.cs @@ -114,7 +114,14 @@ namespace OpenSim.Region.Environment.Modules.InterGrid if (m_scene.Count == 0) { scene.AddLLSDHandler("/agent/", ProcessAgentDomainMessage); - ServicePointManager.ServerCertificateValidationCallback += customXertificateValidation; + try + { + ServicePointManager.ServerCertificateValidationCallback += customXertificateValidation; + } + catch (NotImplementedException) + { + m_log.Error("[OGP]: Certificate validation handler change not supported. You may get ssl certificate validation errors teleporting from your region to some SSL regions."); + } } if (!m_scene.Contains(scene)) -- cgit v1.1