First, we look at how to configure this with the TodoListService project.
Open the web.config file and replace the following keys:
- Search for the ida:Tenant key. Replace its value with your AD tenant name, for example, contoso.onmicrosoft.com. This will also be part of any of the application's APP ID URL.
- Replace the ida:Audience key. Replace its value with https://[Your_AD_Tenant_Name]/TodoListService.
Replace [Your_AD_Tenant_Name] with the name of your Azure AD tenant.
Now let's see how to configure this with the TodoListWebApp project.
Open the web.config file and find and replace the following keys with the provided values:
- Replace todo:TodoListResourceid with https://[Your_Tenant_Name]/TodoListService.
- Replace todo:TodoListBaseAddress with https://localhost:44321/.
- Replace ida:ClientId with the application ID of ToDoListWebApp. You can get it by navigating to App Registration | TodoListWebApp.
- Replace ida:AppKey with client_secret that we generated in step 2 of the process of registering TodoListWebApp. If you missed noting this key, you need to delete the previous key and generate a new key.
- Replace ida:Tenant with your AD tenant name, for example, contoso.onmicrosoft.com.
- Replace ida:RedirectUri with the URL you want the application to redirect to when the user signs out of TodoListWebApp. In our case, the default is https://localhost:44322/ since we want the user to navigate to the home page of the application.