如何让.net程序支持TLS1.2
时间:2018-06-19 14:04:02
收藏:0
阅读:1626
1.将.Net FrameWork设置成4.6以上版本

2.在需要的类中引入命名空间
using System.Net;
3.在程序调用接口(如支付)的地方,加一段代码即可
System.Net.ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
评论(0)