Using SQL Server Integrated Security with Liquibase

From what I have read, we require the the mssql-jdbc_auth dll in order to use a connection string that includes “IntegratedSecurity:true”. My liquibase.properties files has the following connection string:

liquibase.command.url=jdbc:sqlserver://dbLocation;portNumber=1433;databaseName=db_name;encrypt=true;trustServerCertificate=true;integratedSecurity=true;

I have changed nothing about my liquibase installation, everything has worked out of the box. For this issue I have downloaded the mssql-jdbc_auth dll from here: Download - JDBC Driver for SQL Server | Microsoft Learn and extracted the dll to another location and added that location to my account environment variables.

It still does not seem to work. Still getting the following error:

Unexpected error running Liquibase: Connection could not be created to jdbc:sqlserver://dbLocation;portNumber=1433;databaseName=db_name;encrypt=true;trustServerCertificate=true;integratedSecurity=true; with driver com.microsoft.sqlserver.jdbc.SQLServerDriver. This driver is not configured for integrated authentication. ClientConnectionId:6234d58c-8cf6-45af-8991-4e5d50681261

  • Caused by: Unable to load authentication DLL mssql-jdbc_auth-11.2.1.x64

In SSMS I am able to connect to the database using windows authentication

Is there anything I am missing that might help with this, was I supposed to do more than adding the dll to my account’s Path variable?

Problem has been solved after restarting my machine. The Path variable pointing to the auth dll seemed to work accurately after that