Solved

The remote certificate is invalid according to the validation procedure.

Posted on 2009-05-18
1
2,577 Views
Last Modified: 2013-11-30
Hello,
I'm trying to send E-mail using System.Net.Mail in a Windows Forms application in C#.
I'm getting the following error..

"The remote certificate is invalid according to the validation procedure."

Please help me with this..
Thanks,.
0
Comment
Question by:godwindotnet
1 Comment
 
LVL 31

Accepted Solution

by:
Paranormastic earned 500 total points
ID: 24411860
There are 3 primary reasons why a cert won't validate:

1) Name mismatch - make sure the site name matches exactly as it is in the cert.  If there is a "Subject Alternative Name" (SAN) on the details tab, then make sure the name is in that list (note: subject name must also be included in the SAN).  Some applications don't supports SANs, but most do.  Also note that site1 and site1.domain.com are not the same - this is the most common mistake.

2) Untrusted - you need to install the root certificate into the trusted root certificate store.  If this app uses the Microsoft root store, you can check Certificates MMC to see if it shows up.  If not, view the details of the certificate from the error box, go to the certification path tab and double click the topmost certificate, go to details tab and Copy to File button to export it, then from your saved copy you can import it to the trusted root store.

3) Expired or not yet valid - usually from the cert expiring - renew it.  Can also happen if the time/time zone/date/year is off in the client OS - if this is ok, try also checking the same in BIOS.

If this doesn't get you in the right direction, you need a little bit more specific details how it is not coming up as valid - if you have a debug version try doing that so you can get more details.  If you are writing an app that deals with certs, you should try to mimic each of the 3 sections above for correct error handling and better warning messages.
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Hello Friends, My friends and relatives always ask me how to delete all the various types of emails at once in our g-mail  or windows live account.  So I researched this topic to find a unique solution to this query.  Here it is for those who do …
SSL stands for “Secure Sockets Layer” and an SSL certificate is a critical component to keeping your website safe, secured, and compliant. Any ecommerce website must have an SSL certificate to ensure the safe handling of sensitive information like…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now