ssl - Use TLS 1.2 in TFS Webhooks -


i'm trying setup webhook in tfs target internal https server. i'm getting error when attempt test url:

system.net.http.httprequestexception: error occurred while sending request.
---> system.net.webexception: request aborted: not create ssl/tls secure channel.
@ system.net.httpwebrequest.endgetrequeststream(iasyncresult asyncresult, transportcontext& context)
@ system.net.http.httpclienthandler.getrequeststreamcallback(iasyncresult ar)
--- end of inner exception stack trace ---
@ system.runtime.compilerservices.taskawaiter.throwfornonsuccess(task task)
@ system.runtime.compilerservices.taskawaiter.handlenonsuccessanddebuggernotification(task task)
@ microsoft.visualstudio.services.servicehooks.common.httpactiontask.

the could not create ssl/tls secure channel error happens because tfs uses tls 1.0 open connection remote server, , server accepts tls 1.2 requests.

how can configure webhook use tls 1.2?

try before make request:

servicepointmanager.securityprotocol = securityprotocoltype.tls12; 

hope helps


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -