【发布时间】:2018-01-27 01:08:41
【问题描述】:
我正在尝试在 TFS 中设置一个 Webhook,以针对内部 HTTPS 服务器。
当我尝试测试 url 时出现此错误:
System.Net.Http.HttpRequestException:发送时出错 请求。
---> System.Net.WebException:请求被中止: 无法创建 SSL/TLS 安全通道。
在 System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult、TransportContext& 上下文)
在 System.Net.Http.HttpClientHandler.GetRequestStreamCallback(IAsyncResult ar)
--- 内部异常堆栈跟踪结束 ---
在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务 任务)
在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(任务任务)
在 Microsoft.VisualStudio.Services.ServiceHooks.Common.HttpActionTask。
出现Could not create SSL/TLS secure channel 错误是因为TFS 使用TLS 1.0 打开与远程服务器的连接,而该服务器只接受TLS 1.2 请求。
我们如何配置 Webhook 以使用 TLS 1.2?
【问题讨论】: