📌  相关文章
📜  现有连接被远程主机强行关闭. .net core - C# 代码示例

📅  最后修改于: 2022-03-11 14:49:22.240000             🧑  作者: Mango

代码示例1
// If you face error while making inter service call in .net framework. (WEB API 2.0)
// user the below code before making an inter service call

ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12;

// if want to use existing security protocols with new protocols
ServicePointManager.SecurityProtocol |= SecurityProtocolType.Tls | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12;