Reputation: 144
I used AcquireTokenAsync for authenticating with Azure Active directory.
below is the code
var uc = new UserCredential(username, password);
var s = var s = await authenticationContext.AcquireTokenAsync("https://graph.windows.net", _clientId, uc);
the problem is that when I run the code, I get
"unknown_user_type: Unknown User Type"
Upvotes: 4
Views: 11459
Reputation: 1982
Usually, this would indicate that the user you are attempting to sign-in with is not a user whose account is mastered in the tenant whose authority was passed in to the ADAL constructor. This can happen if the authority passed is the pseudo tenant 'common', or if the user is a guest account. Many times the user ends up being an MSA account that is a guest in the desired account. Try using an account that is an AAD account mastered in that particular tenant.
Upvotes: 2