Monday, June 4, 2012

A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: SSL Provider, error: 0 - The certificate chain was issued by an authority that is not trusted

I struggled with this for 2 hours. So for development purpose you can disable the encryption in connection string and it will work.

In connection String Change
Encrypt=True;   ->  Encrypt=False;

Here is working connection String

Server=ServaeName;Database=dbName;User ID=userName;Password=myPassword;Trusted_Connection=False;Encrypt=False;

Thanks

2 comments: