今天在后台向微信服务器请求JSON数据时,返回了错误:The request was aborted: Could not create SSL/TLS secure channel.

查了一下,原来去年SSL协议曝出高危漏洞后,微信公众平台关闭了SSLv2、SSLv3版本支持,请求数据时应该使用TLS或更高版本。

//在请求之前修改安全协议为TLS
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls;

 

至于SSL和TLS的区别,参考这篇文章:http://hengstart.iteye.com/blog/840561

相关文章:

  • 2022-02-26
  • 2021-07-10
  • 2022-12-23
  • 2022-03-04
  • 2022-12-23
  • 2021-10-23
  • 2021-10-22
  • 2022-12-23
猜你喜欢
  • 2021-11-28
  • 2021-07-09
  • 2022-12-23
  • 2022-12-23
  • 2021-06-21
  • 2021-09-14
相关资源
相似解决方案