Hello!
i have just downloaded the mobile trial version and started with connecting to
my mysql server without ssl and it worked great. Then i inserted the ssloptions
and it says "Cannot load CA certificate.".
string vSource2 = "User Id=user; Password=pass; Host=192.168.1.180; Database=db; Protocol=SSL;";
mycon = new MySqlConnection(vSource2);
mycon.SslOptions.CACert = "cacert.pem";
mycon.SslOptions.Cert = "client-cert.pem";
mycon.SslOptions.Key = "client-key.pem";
mycon.Open();
i use the certificates with another connector the odbc/NET and it works so its nothing wrong with them.
i have tried all the diffrent paths file://cacert.pem and with the application.startuppath.
check with File.exits("cacert.pem") and its there.
whats wrong? am greatful for all the help i can get!
Cannot load CA certificate.
-
- Devart Team
- Posts: 2420
- Joined: Wed 02 Nov 2011 09:44
Re: Cannot load CA certificate.
We can reproduce the issue only if we set a wrong path in the mycon.SslOptions.CACert property. If you get "Cannot load CA certificate." exception, that means that you have a correct path for
Please check one more time, whether the cacert.pem file is in the root of your device.
Please also provide the inner exception.
Code: Select all
mycon.SslOptions.Cert = "client-cert.pem";
mycon.SslOptions.Key = "client-key.pem";
Please also provide the inner exception.