none
Program utilizing old version of .NET library? RRS feed

  • Question

  • I have a website written using ASP.NET MVC.  The project was originally written using an older version of .NET (pre 4.5).  I've updated the project to a 4.7.1 by changing the in Target Framework in Properties.

    I'm trying to make a call to PayPal via their library, and I'm getting an exception with the error message "The request was aborted: Could not create SSL/TLS secure channel."  I'm wondering if my application is still linked to/utilizing an older version of whatever .NET library.  Is that possible? 

    If so, how can I determine if that is the case, and if so, how do I get the application to use the current version of the library?  And which library would we be talking about?

    Thanks in advance for any help,

    Richard

    Wednesday, March 4, 2020 1:12 AM

Answers

  • Hi RichardR,

    Thank you for posting here.

    Based on my research for the exception, you need to make ServicePointManager setting at the beginning.

    ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;

    Here's a reference you can refer to:

    The request was aborted: Could not create SSL/TLS secure channel

    Hope it can help you.

    Best Regards,

    Xingyu Zhao


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Marked as answer by RichardR Thursday, March 5, 2020 12:13 AM
    Wednesday, March 4, 2020 6:10 AM
    Moderator

All replies

  • Follow their instruction in ".NET " section here to enable TLS1.2.
    Wednesday, March 4, 2020 1:30 AM
    Answerer
  • Hi RichardR,

    Thank you for posting here.

    Based on my research for the exception, you need to make ServicePointManager setting at the beginning.

    ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;

    Here's a reference you can refer to:

    The request was aborted: Could not create SSL/TLS secure channel

    Hope it can help you.

    Best Regards,

    Xingyu Zhao


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Marked as answer by RichardR Thursday, March 5, 2020 12:13 AM
    Wednesday, March 4, 2020 6:10 AM
    Moderator
  • Thank you, adding that statement resolved that issue <G>
    Thursday, March 5, 2020 12:14 AM