I have set up authentication with Azure Active Directory, in a new App Registration. I am following this (
Some configuration changes in appsettings ,logindisplay.razor ,startup.cs are to be made to authenticate with azure ad. Ex: In appsettings.json ,
"AzureAd": {
"Instance": "https://login.microsoftonline.com/",
"Domain": " ",
"TenantId": " ",
"ClientId": " "
},
If app is already configured to be in required authentication mode , you can directly register application in azure ad portal as you are already doing and add the callback url of your application.
Reference: ASP.NET Core and Blazor Code Venture: Configuring Azure AD Authentication (vmsdurano.com)
You can refer this which help authenticates users with Azure Active Directory (Azure AD) and then acquires an Access Token for Microsoft Graph and calls the Microsoft Graph API.
CodePudding user response:
I ended up making a new project where I did it from scratch, end then copied the relevant files and code into my existing project!