The request was aborted: Could not create secure channel

hrach97
Helper

The request was aborted: Could not create secure channel

Hi,

 

I'm sorry for the question, which has been asked maybe hundred of times, but I just can't solve the problem.

 

using (HttpWebResponse response = request.GetResponse() as HttpWebResponse) {...}

This line throws {"The request was aborted: Could not create SSL/TLS secure channel."} exception.

I have tried to regenerate .p12 file:

openssl pkcs12 -export -out <desired p12 file name>.p12 -inkey <key name which I have downloaded before project creation>.pem -in cert.pem

And my App.config looks like:

    <add key="visaUrl" value="https://sandbox.api.visa.com/" />
    <add key="cert" value="<path to p12 file>.p12" />
    <add key="password" value="<project password>" />
    <add key="certPassword" value="<cert password>" />
    <add key="userId" value="<user id>" />
    <add key="ClientSettingsProvider.ServiceUri" value="" />

 

 

2 REPLIES 2
hrach97
Helper

Re: The request was aborted: Could not create secure channel

I get this exception when just debugging all test via VS19.
API_Products
Visa Developer Support Specialist

Re: The request was aborted: Could not create secure channel

Hey @hrach97,

 

Please refer to this community forum post on how to resolve the issue - https://community.developer.visa.com/t5/Connection-Security-Errors/Could-not-create-SSL-TLS-secure-c...




Thanks,

Diana H.



Was your question answered? Don't forget to click on "Accept as Solution" to help other devs find the answer to the same question.