PC SOFT

PROFESSIONAL NEWSGROUPS
WINDEVWEBDEV and WINDEV Mobile

Home → WEBDEV 2024 → TLS 1.2 support in EmailStartSMTPSession()
TLS 1.2 support in EmailStartSMTPSession()
Started by Vilius, Jul., 21 2022 9:29 AM - 4 replies
Registered member
3 messages
Posted on July, 21 2022 - 9:29 AM
Does anyone which version of WebDev started to support TLS 1.2 in EmailStartSMTPSession()?

I've read multiple posts on the internet that WebDev uses WinInet and Schannel to make TLS socket connections, however from my experiments it seams that no matter which Windows OS I use, or how WinInet is configured, EmailStartSMTPSession() always tries to establish a connection with hardcoded TLS 1.0 parameters. For example if I disable TLS 1.0 it doesn't switch to 1.1 or 1.2 and just produces schannel error.

P.S. Before anyone suggests, I cannot use EmailConfigure() as our application is still running under WebDev 22 and we won't rewrite it to WebDev 26 just to that purpose, so ideally I would want to know exact versions when TLS 1.2 became supported.
Registered member
385 messages
Popularité : +13 (13 votes)
Posted on July, 21 2022 - 9:57 AM
Hi,

We were able to successfully use EmailConfigure() on a WebDev 24 project to make it compatible with TLS 1.2. The documentation seems to imply that it'd be possible on a WebDev 23 project, as that's the first one that supports EmailConfigure() on websites.

For projects on older versions, we had to rely on command-line tools (most usually CMail.exe) called with ExeRun() and the correct list of arguments. But sometimes that's more work than just migrate to a new version.

If you have full access to your server, an other solution would be to install a local SMTP server without any TLS config and make it act as a smart host that relays your emails to the TLS 1.2 SMTP server. Handling of the TLS handshake would then be the responsability of the smart host, not WebDev.
Registered member
3 messages
Posted on July, 21 2022 - 1:07 PM
I appreciate you response. As I said I cannot use EmailConfigure() because it is not available on WebDev 22.

My question was regarding TLS 1.2 in *default* EmailStartSMTPSession implementation, i.e. when it is used with native WinInet implementation on Windows. Does anyone know which version of WebDev started to support TLS 1.2 in EmailStartSMTPSession without switching to EmailConfigure()?
Registered member
3 messages
Posted on July, 27 2022 - 8:33 AM
Just leaving it here for others:

I've got a vague response from the support that TLS is auto-negotiated since WebDev version 23. Earlier versions have TLS version hardcoded unfortunately. The related blog post https://blogs.pcsoft.fr/fr/protocole-tls-version-utilisee-lors-echanges-tcp-serveur/281474976711009/read.awp
Posted on November, 14 2023 - 5:45 PM
worked for me with Windev 22 : EmailParamètre(emailParamètreMode, optionSSL)
Supports TLS1.2