C# 解决网站安全凭证问题
方法一:添加安全凭证
方法二: 添加安全性凭证代码
添加.net安全程序集
using System.Security.Authentication;
using System.Security.Cryptography.X509Certificates;
添加远程安全返回事件
private bool CheckValidationResult(Object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors errors)
{ return true; }ServicePointManager.ServerCertificateValidationCallback = new RemoteCertificateValidationCallback(CheckValidationResult);
此方法必须在创建Url之前