I am using jTDS driver to connect to a SQL Server database. I don't want to provide my Windows Domain username and password but would like to make use of Trusted_connection property in my connection string. However it seems as per this jTDS driver FAQ page there is no property named Trusted_connection
supported by jTDS driver.
Given the application and SQL Server database are on the same host and I have ntlmauth.dll
installed correctly, how do I take advantage of Trusted_connection
property so that I don't have to specify username/password?
Is it that jTDS automatically makes use of Domain username and password as soon as it spots useNTLMv2
and domain
properties being used as shown in the following connection url?
jdbc:jtds:sqlserver://DBHostName:Port/DatabaseName;useNTLMv2=true;domain=DomainName
NB: I could test this myself if only I have access to the code of the application.
As described in the file README.SSO, you need not specify any credentials.
You need not specify the useNTLMv2 parameter either, if you do it determines the version of NTLM that will be used, not IF NTLM will be used or not.