- Surgemail smtp outgoing settings windows 10 install#
- Surgemail smtp outgoing settings windows 10 code#
The server is using a self-signed certificate which cannot be verified.Ĭms_1 | 2. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: : cannot open shared object file: No such file or directoryĪt ())Ĭms_1 | ServerCertificateValidationCallback X509Certificate Issuer=CN=Let's Encrypt Authority X3, O=Let's Encrypt, C=US, Subject=CN=Ĭms_1 | ServerCertificateValidationCallback sslPolicyErrors=RemoteCertificateChainErrorsĬms_1 | ServerCertificateValidationCallback chain=509Certificates.X509Chain ChainStatus=509Certificates.X509ChainStatusĬms_1 | RevocationStatusUnknown - unable to get certificate CRLĬms_1 | An error occurred while attempting to establish an SSL or TLS connection.Ĭms_1 | The SSL certificate presented by the server is not trusted by the system for one or more of the following reasons:Ĭms_1 | 1. > System.DllNotFoundException: Unable to load shared library '' or one of its dependencies. > System.TypeInitializationException: The type initializer for 'HttpInitializer' threw an exception. > System.TypeInitializationException: The type initializer for 'Http' threw an exception. The certificate presented by the server is expired or invalid. The local system is missing a Root or Intermediate certificate needed to verify the server's certificate.ģ. The server is using a self-signed certificate which cannot be verified.Ģ. The SSL certificate presented by the server is not trusted by the system for one or more of the following reasons:ġ. (: An error occurred while attempting to establish an SSL or TLS connection. I hope this helps someone else in future. It's a bit strange that this particular error message comes up when a library is missing and all SSL options are turned off.
Surgemail smtp outgoing settings windows 10 install#
net 2.1 runtime installation doesn't actually install all the pre-requisites required for Mailkit. net runtime libcurl.Īfter running the following command it immediately started working without error: The resolution turned out to be a missing pre-requisite that was not installed with the. When I completely turned off SSL in MailKit and also overrode the certificate check and it still gave the same error about the certificate I knew something more was up.
Surgemail smtp outgoing settings windows 10 code#
net 2.1 runtime and got the error stack trace in the block below when using IMAP to connect to the mail server.īecause the error specifically states it's a certificate issue I spent a lot of time trying many different things including opening the mail server non SSL port for IMAP and turning off SSL in my code completely, everything worked no matter what I did on my local Windows dev station but not on the Linux server. We recently ported our online services to Linux so I installed it on Linux with the.
It worked fine on a Windows server for months. The application is an internal company app that uses IMAP to check for mail and display it in a web page. I have a asp.net Core 2.1 project with Mailkit 2.0.5 on Ubuntu 16.04.4 and a Surgemail mail server we host ourselves. This was a vexing problem that I found a solution for and am posting in case anyone else runs into this issue.