a.guelle
Posts: 97
Joined: Tue May 19, 2015 2:23 pm

[solved] Force client TLS encryption on custom SQL Server connection with certificate check

Hi everone,

Using the SQL server you have two options to ensure an encrypted connection. You can enforce the encryption by the server or you enforce it by each client individually.

Enforcing TLS encryption by the client works like the follwing:

- Using SQLCMD the parameter

Code: Select all

-N
enforces encryption and checks the certificate
- Using JDBC the parameter

Code: Select all

encrypt=true;trustServerCertificate=false;
does the same

So what is the parameter for TLS encryption when using a custom connection String in the SQL Databases configuration page of Advanced Installer:

Code: Select all

Driver=[\{]SQL Server[\}];Server=[SERVER_PROP],[PORT_PROP];Uid=[SA_USERNAME_PROP];Pwd=[SA_PASSWORD_PROP];??
Best regards,

Angelo
a.guelle
Posts: 97
Joined: Tue May 19, 2015 2:23 pm

Re: [solved] Force client TLS encryption on custom SQL Server connection with certificate check

Though I searched for an hour before posting this question, I now found the solution own:

https://www.connectionstrings.com/sql-server/

Code: Select all

Driver=[\{]SQL Server[\}];Server=[SERVER_PROP],[PORT_PROP];Uid=[SA_USERNAME_PROP];Pwd=[SA_PASSWORD_PROP];Encrypt=yes;
Catalin
Posts: 6585
Joined: Wed Jun 13, 2018 7:49 am

Re: [solved] Force client TLS encryption on custom SQL Server connection with certificate check

Hello Angelo,

Thank you for your followup on this and for sharing your solution with us.

I am sure this will be of help for further users facing a similar scenario.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”