mirror of
https://github.com/opensim/opensim.git
synced 2026-05-15 03:15:41 +08:00
Fix the cert validation handler so that it will not block other parts of
the server doing ssl successfully.
This commit is contained in:
@@ -118,7 +118,15 @@ namespace OpenSim.Region.CoreModules.Scripting.HttpRequest
|
||||
return true;
|
||||
}
|
||||
|
||||
return chain.Build(new X509Certificate2(certificate));
|
||||
if ((((int)sslPolicyErrors) & ~4) != 0)
|
||||
return false;
|
||||
|
||||
if (ServicePointManager.CertificatePolicy != null)
|
||||
{
|
||||
ServicePoint sp = Request.ServicePoint;
|
||||
return ServicePointManager.CertificatePolicy.CheckValidationResult (sp, certificate, Request, 0);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
#region IHttpRequestModule Members
|
||||
|
||||
@@ -464,4 +472,4 @@ namespace OpenSim.Region.CoreModules.Scripting.HttpRequest
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user