As I am able to configure my SQL Server and client to establish SSL connection, I have installed the certificate on the server as well as on the client machine (Trusted Root Certification Authorities store).
If I have only one certificate on server and client, it is working fine.
Now my question.
If I have multiple certificates on both machines then I need to attach the certificate to the SQL server which I want to use, but I am not telling my client which certificate to use. Then how does the client pick the correct certificate from its store for handshaking with SQL Server?
Does it loop through all the certificates from its store and get the one matching with the SQL Server's certificate?
How does the client identify the correct certificate (generally it exchanges the public keys from the certificate) from its store?
Is there any way to configure the client to use XXXX certificate for the SQL Server 1 and YYYY certificate for the SQL Server 2?