msal

how to get Facebook profile picture using Azure AD B2C

余生颓废 提交于 2019-12-05 00:47:33
问题 I am using MSAL.js and could successfully sign-in/sign-up users in Azure AD B2C using Facebook as identity provider. The problem is that after sign-in I cannot retrieve user's profile picture. Azure AD B2C returns an object identifier which has no tie to user's Facebook id. 回答1: Using custom policies, you can retrieve the picture field for the Facebook user and then issue a picture claim in the ID token, as follows. 1: Complete the Azure Active Directory B2C: Get started with custom policies

What is the unique id for users in OpenId Connect

孤街浪徒 提交于 2019-12-05 00:46:57
问题 We have an Asp.Net 4.5 MVC app using Asp.Net Identity to manage our customer database. We are currently using Microsoft Account Authentication. We are considering using OpenId Connect so that customers with a work/school account can also sign-in Add sign-in to an .NET MVC web app. Microsoft Account Authentication returns ProviderKey as the unique id of the user who has logged in. This is mapped onto UserId in our customer database. OpenId Connect does not appear to return a ProviderKey, but

iOS ADAL-Make silent call using refresh token

会有一股神秘感。 提交于 2019-12-04 19:33:13
I am using iOS ADAL library version 2.2.6 and receiving refresh token upon successful login. Now I want to make a silent call by using this refresh token. I tried with following method but it fails to return the access token. ADAuthenticationContext *authContext; [authContext acquireTokenSilentWithResource:resourceId clientId:clientId redirectUri:redirectUri userId:strUserID //loggedIn userID completionBlock:^(ADAuthenticationResult *result){ // It alway throws an error //Please call the non-silent acquireTokenWithResource methods. if(result.error){ ADAuthenticationError *error = nil;

Authentication on angular spa using msal.js

不想你离开。 提交于 2019-12-04 06:01:20
my angular app has 1000s unique routes and users should be able to click on login button from any of those pages. Have implemented msal.js basing on this sample : https://github.com/Gimly/simpleAngularAzureB2C/blob/master/src/app/authentication.service.ts I am getting following error when calling login method: AADB2C90006:+The+redirect+URI+' http://localhost:39579/unique-uri '+provided+in+the+request+is+not+registered+for+the+client+id+ Is there a way to get around this? Thanks! By default, the Msal.UserAgentApplication constructor sets the "redirect_uri" request parameter to the current URL,

MSAL UserAgentApplication: Local storage not working

此生再无相见时 提交于 2019-12-04 04:33:56
问题 UserAgentApplication.localCache = "localStorage" is not working. Steps to reproduce: var client = new Msal.UserAgentApplication(config.aadClientId, config.aadAuthority...); client.cacheLocation = "localStorage"; client.loginPopup().then( ... ); Result: The MSAL tokens are stored in session storage. (Chrome developer tools) Expected: Tokens should be in local storage. I am using msal 0.1.1 javascript library via https://secure.aadcdn.microsoftonline-p.com/lib/0.1.1/js/msal.min.js 回答1: As a

What is the difference between ADAL.js and MSAL.js?

╄→尐↘猪︶ㄣ 提交于 2019-12-04 01:37:12
I am trying to handle authentication for my app which uses Microsoft Graph. What is the difference between these two libraries? Active Directory Authentication Library for JavaScript (ADAL.js) Microsoft Authentication Library for JavaScript (MSAL.js) Is ADAL.js just an Angular 1 library of MSAL.js? MSAL.js works with the AzureAD V2 endpoint, whereas ADAL.js works with the AzureAD V1 endpoint. The V1 endpoint supports work accounts, but not personal accounts. The V2.0 endpoint is the unification of Microsoft personal accounts and work accounts into a single authentication system. Finally, with

how to get Facebook profile picture using Azure AD B2C

微笑、不失礼 提交于 2019-12-03 16:02:32
I am using MSAL.js and could successfully sign-in/sign-up users in Azure AD B2C using Facebook as identity provider. The problem is that after sign-in I cannot retrieve user's profile picture. Azure AD B2C returns an object identifier which has no tie to user's Facebook id. Using custom policies, you can retrieve the picture field for the Facebook user and then issue a picture claim in the ID token, as follows. 1: Complete the Azure Active Directory B2C: Get started with custom policies steps with one of the social account policies such as the SocialAndLocalAccounts one. 2: Declare a "picture"

How do I get the logged in users profile for Azure AD OAuth logins?

此生再无相见时 提交于 2019-12-02 05:08:47
Following on from JavaScript OAuth2 flow for Azure AD v2 login does not give an access_token , I'm trying to figure out the best endpoint to use, to get the logged in users details (eg, display name, email, etc.). However, I noticed in there are 2 potential endpoints I can use https://outlook.office.com/api/v2.0/me https://graph.microsoft.com/v1.0/me 1, is used in bell for hapijs and is documented in Use the Outlook REST API . However, in bell, I can't seem to figure out the scope I need to get it working for OAuth 2.0. I've tried openid , email , profile , Mail.Read (only trying this because

Microsoft graph API: Unable to fetch users with the generated access token

孤街醉人 提交于 2019-12-02 04:32:58
问题 I have registered the application in Azure portal and i have generated the client_secret. I require the client grant flow and i have given application permissions also. I have granted the admin consent also as I am the admin myself. I am able to generate the access token with the given url: https://login.microsoftonline.com/47be0abf-c6a1-4f04-a665-dceb081c4ff1/oauth2/v2.0/token?client_id=********&client_secret=******&grant_type=client_credentials&scope=User.ReadBasic.All%20User.Read%20User

Microsoft graph API: Unable to fetch users with the generated access token

旧街凉风 提交于 2019-12-02 01:53:15
I have registered the application in Azure portal and i have generated the client_secret. I require the client grant flow and i have given application permissions also. I have granted the admin consent also as I am the admin myself. I am able to generate the access token with the given url: https://login.microsoftonline.com/47be0abf-c6a1-4f04-a665-dceb081c4ff1/oauth2/v2.0/token?client_id=********&client_secret=******&grant_type=client_credentials&scope=User.ReadBasic.All%20User.Read%20User.ReadWrite%20User.Read.All%20User.ReadWrite.All%20Directory.Read.All%20Directory.ReadWrite.All%20Directory