Windows Authentication for SQL Server using JBDC on a Mac

后端 未结 6 905
小蘑菇
小蘑菇 2021-02-01 07:21

Is it possible to connect to SQL Server using Windows authentication/integrated security from a Mac? I am using the type 4 JDBC driver provided by Microsoft. The front end (a fo

6条回答
  •  旧时难觅i
    2021-02-01 07:31

    This information is hard to come by in my experience. All of my searches turned up wrong (outdated) information since Microsoft changed the rules and added the authenticationScheme parameter. In the interest of helping the next person, here is an example of a connection string that works:

    jdbc:jtds:sqlserver://123.123.123;instance=server1;databaseName=students;integratedSecurity=true;authenticationScheme=JavaKerberos
    

    Also in driver properties set "Domain". Do not include the domain in any user name setting.

    This was tested using Squirrel SQL (Java) with jtds on Mac OSX. Hopefully the previous sentence has the search terms someone might use who needs to know this information.

提交回复
热议问题