8

Since 10.2, SQL Server enables SSL by default, which is a breaking change by their own admission:

https://learn.microsoft.com/en-us/sql/connect/jdbc/release-notes-for-the-jdbc-driver?view=sql-server-ver16#changes-in-102

Now, the question is how to adapt an existing, good/working JDBC connection string to not use encryption. E.g. what should this URL become?

jdbc:sqlserver://localhost:1433;databaseName=SomeDatabase;
Dave Ankin
  • 1,060
  • 2
  • 9
  • 20
  • someone should add the right tags to this. it took me 20 mins to find the answer in the docs which is the sweet spot for where i think it start being the docs' fault rather than mine for not being organized well enough. – Dave Ankin Jul 24 '22 at 23:35

1 Answers1

11

Seems to be just add encrypt=false; to the end, and the app starts up again.

Dave Ankin
  • 1,060
  • 2
  • 9
  • 20
  • Yes, this would be backed up by [Step 3: Proof of concept connecting to SQL using Java](https://learn.microsoft.com/en-us/sql/connect/jdbc/step-3-proof-of-concept-connecting-to-sql-using-java) which shows the opposite (normal) case of `encrypt=true;` in the connection string. – AlwaysLearning Jul 24 '22 at 23:38