Before using ADAL.NET you will have to register you applications with Azure AD.
Azure AD currently supports several kinds of applications, depending on the type of users they target:
- Azure AD v1.0 applications, let users sign-in with their work and school account, use ADAL.NET and need to be registered in the Azure portal (https://portal.azure.com). If you are not familiar with v1.0 application registration, you might want to follow the following tutorial: Integrate Azure AD into a Windows Desktop WPF App. Reading the following article will also be valuable: Integrating applications with Azure Active Directory
- Azure AD v2.0 application lets users sign-in with their work and school accounts or their personal accounts. Use MSAL.NET, which is a different library, currently in Preview, if that's what you want to do
The picture below shows in which case you want to use ADAL.NET: when you want the users of the application to sign-in with Azure AD (work and school accounts), or Active Directory FederationServices (ADFS)
Note that the application registration is different depending on if you are registering a public client application (Mobile / Desktop app), or a Confidential client application (Web App / Web API / daemon application). For instance:
- See Integrate Azure AD into a Windows Desktop WPF App for a desktop application
- See Add sign-in with Microsoft to an ASP.NET web app for a Web Application
No comments:
Post a Comment