只添加以下代码先试试(代码多了有可能会不好使):
//添加https兼容处理 HttpWebRequest request = null; if (url.StartsWith("https", StringComparison.OrdinalIgnoreCase)) { ServicePointManager.SecurityProtocol = (SecurityProtocolType)3072; request = WebRequest.Create(url) as HttpWebRequest; } else { request = (HttpWebRequest)WebRequest.Create(url); }