An error occurred while attempting to establish an SSL or TLS connection while sending email

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
3 years ago
I am going to setup email account of my store. I have installed two version of nopcommerce (4.20, 4.30) for test purpose.
I have configured email account like below...
Email Address: [email protected]
Display Name: Test Store
Host: smtp.mydomain.com
port: 587 or 25
user: [email protected]
pass: <Password>
SSL: False
Use default credential: False

In both installed version (4.20 and 4.30) ssl certificate was installed at server but later I have delete or uninstall that.

From installed version 4.20 I can send test email successfully using both port 25 and 587.
But while going to send email from installed version 4.30 it fails and shows error like below..
An error occurred while attempting to establish an SSL or TLS connection. This usually means that the SSL certificate presented by the server is not trusted by the system for one or more of the following reasons: 1. The server is using a self-signed certificate which cannot be verified. 2. The local system is missing a Root or Intermediate certificate needed to verify the server's certificate. 3. A Certificate Authority CRL server for one or more of the certificates in the chain is temporarily unavailable. 4. The certificate presented by the server is expired or invalid. It is also possible that the set of SSL/TLS protocols supported by the client and server do not match. See https://github.com/jstedfast/MailKit/blob/master/FAQ.md#SslHandshakeException for possible solutions.

Could not understand what wrong I have done.
Please help if anyone face this issue.
3 years ago
Are you using Exchange or Office 365 ?
3 years ago
Thanks for your reply.
No, I am not using Exchange or Office 365.
Just I have created email under domain and add dns records. Using same email address and settings it works for nopCommerce 4.20 but failed at 4.30.
Both applications are hosted at same hosting provider.
3 years ago
We are using office365 and have a similar issue. Any idea?
3 years ago
I don't understand. Is Nop support work? It has an issue.
This function was fine, but broken. I understand - if you are wrote code - you should don't broke previous

I have the same issue
3 years ago
Hello! Team,

We are facing the same error, does anyone know the solution for this?

Thank you,
Anup
3 years ago
I had problem with dns zone record for mail. Make sure that there is correct MX record.
One more thing, if mail server is ssl enabled then use 587 port otherwise use 25 port.
Contact your hosting provider to get the right mail server address and right port.
Before configuring nopcommerce email you may configure it into outlook to see that the mail is sending and receiving correctly.

Thanks.
3 years ago
If you are using Office365, try port 587 and have SSL unchecked
3 years ago
It resolved only by transfer website from http to https.
SSL setting working only with https domain for 4.30 version
But with the previous version 4.20 - it worked with http and https
3 years ago
Thank you for your inputs and time - Monowar, JayC, DMytro.

We followed all the steps pointed out by you, but still we are getting the below error:
We have hosted the No Source version of nopCommerce 4.3 on a windows VPS with a SSL, add we tried with SMTP from Gmail, Office365 and one custom provider too.. still getting the below error,

Any further help to diagnose this issue will be of help to us.  

Thank you,
Anup

"An error occurred while attempting to establish an SSL or TLS connection. This usually means that the SSL certificate presented by the server is not trusted by the system for one or more of the following reasons: 1. The server is using a self-signed certificate which cannot be verified. 2. The local system is missing a Root or Intermediate certificate needed to verify the server's certificate. 3. A Certificate Authority CRL server for one or more of the certificates in the chain is temporarily unavailable. 4. The certificate presented by the server is expired or invalid. Another possibility is that you are trying to connect to a port which does not support SSL/TLS. It is also possible that the set of SSL/TLS protocols supported by the client and server do not match. See https://github.com/jstedfast/MailKit/blob/master/FAQ.md#SslHandshakeException for possible solutions."
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.