'Can't connect to SQL Server from Jetbrains Rider after updating driver to 10.2
I'm using the same credentials as before update. It writes:
[08S01] The driver could not establish a secure connection to SQL Server by using Secure Sockets Layer (SSL) encryption. Error: "PKIX path building failed:
sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target".
ClientConnectionId:ebe9ba87-4c34-4015-b6c8-a151bdf33a67 unable to find valid certification path to requested target
Solution 1:[1]
(Adding here because didn't fit in comments) I don't remember where but it happened to me once when it said no data source was configured for the SQL I wrote. When I went in to configure the data source and updated the driver for SQL server to latest, I had that problem. Replacing the driver with an older one (9.x?) solved the problem. In another project that I am working on now (Rider 2022.1) I could directly go and add an SQL server with no problems (used windows authentication):
DBMS: Microsoft SQL Server (ver. 15.00.2080)
Case sensitivity: plain=mixed, delimited=mixed
Driver: JetBrains JDBC Driver for SQL Server (ver. 1.0, JDBC4.2)
Ping: 78 ms
SSL: no
Solution 2:[2]
Adding Encrypt=false to the JDBC string disables the secure protocol and bypasses the certificate problem.
Solution 3:[3]
In Rider 2022.1 we have implemented JDBC SQL Driver which is able to connect to MS SQL Server in a better way then a default (microsoft) one using named pipes and any kind of authentication. You can use .net connection strings there.
It should work find out of the box. If something does not work please fire an issue in JetBrains public issue tracker:
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Cetin Basoz |
Solution 2 | user2176745 |
Solution 3 | xtmq |