restClient访问SSL

            IRestClient client = new RestClient("https://xxx.com/aa/bb");
var prjIds = "";
var request15 = new RestRequest().AddParameter("prjIds", prjIds).AddParameter("pageLocation", );
ServicePointManager.ServerCertificateValidationCallback = ((a1, b1, c1, d1) => { return true; });
var response15 = client.Execute(request15);
if (response15.StatusCode == HttpStatusCode.OK)
{
var content = response15.Content;
}

再加上下面这句

ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12 | (SecurityProtocolType)3072;

上一篇:leetcode@ [310] Minimum Height Trees


下一篇:Linux添加硬盘和挂载