Accept any certificate for SSL
I have small TcpClient app to connect to a server using SSL (SSlStream class)
My question is, how to accept any ssl certification when co开发者_StackOverflow中文版nnecting?
Thanks,
public static bool RemoteCertificateValidationCallback(object sender,
X509Certificate certificate, X509Chain chain, SslPolicyErrors errors)
{
return true;
}
精彩评论