2

I'm investigating using Azure user-assigned managed identities to access SQL Server from our application which uses EntityFramework 6. I have gotten it to work using this package: https://www.nuget.org/packages/ErikEJ.EntityFramework.SqlServer and connection strings with the following attributes:

Authentication=Active Directory Managed Identity;User Id=<clientId of managed identity>;

However, when running locally I have to use

Authentication=Active Directory Interactive;

It would be better if there were a way to impersonate the managed identity locally in some way so that any schema access issues can be debugged locally. (We have multiple different schemas that different identities can use). Is there any way to do this? I am getting lost in documentation and tutorials at this moment. Any solution would have to work in .NET Core 3.1 and .NET Framework 4.7.2.

Ian
  • 4,169
  • 3
  • 37
  • 62
  • you ve seen this one:https://learn.microsoft.com/en-us/azure/app-service/app-service-web-tutorial-connect-msi?tabs=windowsclient%2Cdotnet – Thomas Sep 29 '21 at 19:26
  • you can then use azure service auth in visual studio – Thomas Sep 29 '21 at 19:27

0 Answers0