The remote certificate is invalid according to the validation procedure.

Jun 18, 2010 at 8:15 PM

Hi Alessandro,

I have a fileZilla server setup on my local machine. I've generated a certificate as per these http://wiki.filezilla-project.org/SSL/TLS instructions.

Now i'm trying to run the following code:

            using(FTPSClient client = new FTPSClient())
            {
                client.Connect("localhost",
                           new NetworkCredential("Brian", "brian"));

            }

I'm getting the following exception "The remote certificate is invalid according to the validation procedure."

Can you tell me what I'm doing wrong?

Coordinator
Jun 18, 2010 at 9:00 PM

Hi Brian,

 

in a nutshell, a certificate is valid when emitted by a trusted certification authority, which is not this case.

You should instruct the client to accept invalid certificates too. Please see this thread about how:

http://ftps.codeplex.com/Thread/View.aspx?ThreadId=44674

Let me know if you have further questions.

 

Cheers,

Alessandro Pilotti [ MVP / IIS ]

Jun 18, 2010 at 9:27 PM
Thanks for the quick reply!

Another question

I would like to know what different ESSLSupportMode's mean. Is there any documentation or online resources you can forward me to?


Thanks,
Brian