// we don't catch exceptions in this method, so it's safe for "accepted" be initialized with true
bool success = false;
-#if MONO
- if (IsServer)
- // FIXME
- success = true;
- else
- success = SSPIWrapper.CheckRemoteCertificate(m_SecurityContext);
-#else
X509Chain chain = null;
X509Certificate2 remoteCertificateEx = null;
GlobalLog.Leave("SecureChannel#" + ValidationHelper.HashString(this) + "::VerifyRemoteCertificate (no remote cert)", (!m_RemoteCertRequired).ToString());
sslPolicyErrors |= SslPolicyErrors.RemoteCertificateNotAvailable;
}
+#if !MONO
else
{
chain = new X509Chain();
else
success = (sslPolicyErrors == SslPolicyErrors.None);
}
+#else
+ success = SSPIWrapper.CheckRemoteCertificate(m_SecurityContext);
+#endif
if (Logging.On) {
if (sslPolicyErrors != SslPolicyErrors.None)
remoteCertificateEx.Reset();
}
GlobalLog.Leave("SecureChannel#" + ValidationHelper.HashString(this) + "::VerifyRemoteCertificate", success.ToString());
-#endif
return success;
}