skip to main content
DataDirect Connect Drivers : Microsoft SQL Server Driver : Authentication : Configuring NTLM Authentication : Configuring the Driver: Not Specifying User Credentials (Windows Only)
  
Configuring the Driver: Not Specifying User Credentials (Windows Only)
To use NTLM authentication without specifying user credentials, the driver must load an NTLM authentication DLL. The product provides the following NTLM authentication DLLs (where xx is a 2-digit number):
*DDJDBCAuthxx.dll (32-bit)
*DDJDBC64Authxx.dll (Itanium 64-bit)
*DDJDBCx64Authxx.dll (AMD64 and Intel EM64T 64-bit)
The DLLs are located in the install_dir/lib directory (where install_dir is your product installation directory). If the application using NTLM authentication is running in a 32-bit JVM, the driver automatically uses DDJDBCAuthxx.dll. Similarly, if the application is running in a 64-bit JVM, the driver uses DDJDBC64Authxx.dll or DDJDBCx64Authxx.dll.
To configure the driver:
1. Set the AuthenticationMethod property to auto (default) or ntlm. See Using the AuthenticationMethod Property for more information about setting a value for this property.
2. By default, the driver looks for the NTLM authentication DLLs in a directory on the Windows system path defined by the PATH environment variable. If you install the driver in a directory that is not on the Windows system path, perform one of the following actions to ensure the driver can load the DLLs:
Add the install_dir/lib directory to the Windows system path, where install_dir is your product installation directory.
Copy the NTLM authentication DLLs from install_dir/lib to a directory that is on the Windows system path, where install_dir is your product installation directory.
Set the LoadLibraryPath property to specify the location of the NTLM authentication DLLs. For example, if you install the driver in a directory named "DataDirect" that is not on the Windows system path, you can use the LoadLibraryPath property to specify the directory containing the NTLM authentication DLLs: jdbc:datadirect:sqlserver://server3:1521;
DatabaseName=test;LoadLibraryPath=C:\DataDirect\lib;
User=test;Password=secret
3. If using NTLM authentication with a Security Manager on a Java 2 Platform, security permissions must be granted to allow the driver to establish connections. See Permissions for Establishing Connections for an example.