I have an existing .NET MVC Web application which is using Windows Authentication. As we are migrating the project from On-Premise to Azure, there is a necessity of updating the application to use Azure AD Authentication. I was trying to use Connected Services using VS 2019, but not able to find Azure AD Authentication related service. Can anyone please share the process to add Azure AD to existing app?
-
Which guide are you following? You shouldn't need to go to "Connected Services." You can publish the app by going to Solution Explorer > Publish > Azure after you have configured the App Service and resource group. Then you can register the application and add the authentication. learn.microsoft.com/en-us/azure/app-service/… learn.microsoft.com/en-us/azure/app-service/…Marilee Turscak - MSFT– Marilee Turscak - MSFT2021-08-20 18:27:13 +00:00Commented Aug 20, 2021 at 18:27
-
There is also a sample for this on Github:github.com/AzureADQuickStarts/…Marilee Turscak - MSFT– Marilee Turscak - MSFT2021-08-20 18:27:28 +00:00Commented Aug 20, 2021 at 18:27
1 Answer
Solution 1:
1) I tried with creating new ASP .NET MVC application project in Visual studio 2019 .click on the Change Under the Authentication
2) Select Work or School Accounts .
3) you can enter a domain name and also select the Read directory data option as desired. Developers typically include this option.
Solution 2:
1) Select the Project > Add Connected Service... menu command, or double-click the Connected Services node found under the project in Solution Explorer
2) On the Connected Services page, select Authentication with Azure Active Directory
3) On the Introduction page, select Next. If you see errors on this page, refer to Diagnosing errors with the Azure Active Directory Connected Service
4) On the Single-Sign On page, select a domain from the Domain drop-down list. The list contains all domains accessible by the accounts listed in the Account Settings dialog of Visual Studio (File > Account Settings...). As an alternative, you can enter a domain name if you don’t find the one you’re looking for, such as mydomain.onmicrosoft.com. You can choose the option to create an Azure Active Directory app or use the settings from an existing Azure Active Directory app. Select Next when done.
5) On the Directory Access page, select the Read directory data option as desired. Developers typically include this option.
6) Select Finish to start modifications to your project to enable Azure AD authentication
For more details refer this document







