West Wind Internet and Client Tools
An error occurred in the secure channel support
Gravatar is a globally recognized avatar based on your email address. An error occurred in the secure channel support
  Hendrik
  All
  Sep 17, 2024 @ 03:26am

Hi Rick. We started having this issue on Windows server 2013 using V7.33

When calling the webservice it will return An error occurred in the secure channel support We had to change the timeout values to 100 to get the error message

Public loSer, loPaymentList, ReturnJSON
loHTTP = Createobject("wwHTTP")
loHTTP.cContentType = "application/json"  && Content type of the data posted
loHTTP.AddPostKey()  		&& Clear POST buffer
loHTTP.AddPostKey(lcJSON)
loHTTP.nconnecttimeout = 100
ReturnJSON = loHTTP.HttpGet("https://XXXXXXX")

It works 100% on Windows 11 and Win Server 2022 This started at the end of August.

Using Postman the call to the webservice works from both the servers

We have ensured that all the DLL used by Client Tools is in the folder.

The webservice is still using TLS1.2

Any suggestions would be appreciated

Gravatar is a globally recognized avatar based on your email address. re: An error occurred in the secure channel support
  Rick Strahl
  Hendrik
  Sep 17, 2024 @ 07:45am

There's no Windows Server 2013. There's Server 2012 and 2012R2.

Both of these do not directly support TLS 1.2 and later I think, so most likely this is the reason this is not working.

Checked now: R2 has support for it out of box. 2012 original requires some registry tweaks to work with it.

More info here:

Web Connection and TLS 1.2 Support

Time to update your Server software. 😄

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: An error occurred in the secure channel support
  Hendrik
  Rick Strahl
  Sep 17, 2024 @ 08:35pm

My apology Rick.

It is Windows Server 2012 R2 Standard. (Typing problem)

This problem started around the end of August as this part of code has been working for quite a while.

Setting the timeout to longer than 30 will give us the return message.

Firewall issues can be excluded as I can connect to the webservices from other software not using Westwind Clienttools 7.33

The following DLL are present in the program folder.

I can confirm that the exact same code and foxpro data used from other servers are still functioning without the issue. No new updates have been done on the server in the recent past. Could it be a certificate issue and if Yes what setting can I use to prevent certificate checking.

I have checked and the same type of code using WestWind Client tools to send SMS from a different service provider is working on this exact same application

If have added the following to that code without success

lohttp.lIgnoreCertificateWarnings = .T.

Any other suggestions?

I really do not know where to continue looking.

Gravatar is a globally recognized avatar based on your email address. re: An error occurred in the secure channel support
  Rick Strahl
  Hendrik
  Sep 18, 2024 @ 07:50am

wwSMTP uses .NET for mail delivery and it doesn't have external dependencies. Since you are using a current version of the Client Tools or Web Connection TLS support should work, regardless of the server in use.

The only thing I can think of is that perhaps the .NET version is old? The original versions that were installed with server 2012 were pre-4.62 which started defaulting to include TLS 1.2 (older versions required explicit setting). However, old or non-patched versions of .NET might have a built-in certificate chain were the built-in root certs have expired.

Also, You can try adding this to your application:

loBridge = GetwwDotnetBridge()
loBridge.SetStaticProperty("System.Net.ServicePointManager","SecurityProtocol",4080)

which enables all protocols.

+++ Rick ---

© 1996-2024