
The application server authenticates as a different database and connects to SQL Server. User logs in to a client machine and authenticates to the application server. In this situation, a developer must configure an application to use integrated authentication: Using Linked Server and Distributed Queriesĭevelopers can deploy an application that uses a linked server or distributed queries without a database administrator who maintains separate sets of SQL credentials. See Microsoft Kerberos for more information. It is possible to configure Active Directory as a key distribution center (KDC) for Integrated Authentication.

Using Active Directory to Manage User IdentitiesĪn application system administrator does not have to manage separate sets of login credentials for SQL Server. For more information, see ODBC Connection Pooling.īefore reuse, an application must reset pooled connections by executing sp_reset_connection.
#Kerberos client linux driver
However, combining connection pooling, Integrated Authentication, and auditing creates a security risk because the unixODBC driver manager permits different users to reuse pooled connections. To improve application performance, an application can use connection pooling with Integrated Authentication and auditing. To audit activities in SQL Server on behalf of users other than the system account, the application must use Transact-SQL EXECUTE AS. Therefore, more is required to determine the user. Logging in to SQL Server uses the system account and there is no functionality on Linux to impersonate security context. Tracking Access to a DatabaseĪ database administrator can create an audit trail of access to a database when using system accounts to access SQL Server using Integrated Authentication. Kerberos Configuration and Use provides details on ways to Kerberize services on Linux.
#Kerberos client linux password
To avoid requiring the password for each renewal, you can use a keytab file. The ODBC driver does not renew credentials itself ensure that there is a cron job or script that periodically runs to renew the credentials before their expiration. When an application runs as a service, because Kerberos credentials expire by design, renew the credentials to ensure continued service availability. Run kinit, passing in a principal name and a location of a keytab file that contains the principal's key created by ktutil.Įnsure that the login to the system was done using the Kerberos PAM (Pluggable Authentication Module). Run kinit, passing in a principal name and password. You first need to configure Kerberos on the client and then ensure that the application can use the Kerberos credential of the default principal.Įnsure that you use kinit or PAM (Pluggable Authentication Module) to obtain and cache the TGT for the principal that the connection uses, via one of the following methods: Deploying a Linux or macOS ODBC Driver Application Designed to Run as a ServiceĪ system administrator can deploy an application to run as a service that uses Kerberos Authentication to connect to SQL Server. ServerSPN and FailoverPartnerSPN are not supported. The -E option of sqlcmd and the -T option of bcp can also be used to specify integrated authentication see Connecting with sqlcmd and Connecting with bcp for more information.Įnsure that the client principal which is going to connect to SQL Server is already authenticated with the Kerberos KDC. When connecting with a DSN, you can also add Trusted_Connection=yes to the DSN entry in odbc.ini.

For example: Driver='ODBC Driver 17 for SQL Server' Server=your_server Trusted_Connection=yes You can enable Kerberos integrated authentication by specifying Trusted_Connection=yes in the connection string of SQLDriverConnect or SQLConnect. Using Integrated Authentication to Connect to SQL Server from an ODBC Application See Using Azure Active Directory for more information.

It supports the MIT Kerberos Key Distribution Center (KDC), and works with Generic Security Services Application Program Interface (GSSAPI) and Kerberos v5 libraries.Īs of version 17.6, the driver also supports integrated authentication with Azure Active Directory using a federated account, system library limitations notwithstanding. The Microsoft ODBC Driver for SQL Server on Linux and macOS supports connections that use Kerberos integrated authentication.
