AzureAD / azure-activedirectory-library-for-js

The code for ADAL.js and ADAL Angular has been moved to the MSAL.js repo. Please open any issues or PRs at the link below.
https://github.com/AzureAD/microsoft-authentication-library-for-js/tree/dev/maintenance/adal-angular
Apache License 2.0
627 stars 372 forks source link

Prompt setting not working as expected if set to select_account #874

Closed xscheiner closed 4 years ago

xscheiner commented 5 years ago

I'm submitting a...


[ ] Regression (a behavior that used to work and stopped working in a new release)
[X] Bug report  
[ ] Performance issue
[ ] Feature request
[ ] Documentation issue or request
[ ] Other... Please describe:

Browser:

Library Name

Library version

Library version: 1.0.17

Current behavior

I had issues with users being unable to log into my app if they were logged in elsewhere with one other ms/live account (not more than one). The problem was the prompt was not coming to allow them to select which account to use even though I had set prompt="select_account" in my config. I had to add an extraQueryParam="prompt=select_account" to make it work. Unless I am not understanding something, it seems the prompt setting should govern this.

Expected behavior

Setting prompt=select_account results in the select account dialog appearing whenever the user is logged into one other ms account.

Minimal reproduction of the problem with instructions

Log into ms with an ms or live account. Open a second tab in the browser and try to log into an app with office 365 using adal with these settings: { popUp: true, instance: "https://login.microsoftonline.com/", tenant: "common", clientId: "CLIENT_ID",, cacheLocation: "localStorage", prompt: "select_account", callback: FUNCTION }

PTC-JoshuaMatthews commented 5 years ago

Did you figure anything out here? I am using the angular library and similarly cannot seem to pass in a prompt parameter

jmckennon commented 4 years ago

This is currently fixed in msal js, though you can also use your stated workaround in adal js.

All current authentication work from Microsoft is delivered through the msal js library here. adal js is still supported only for security fixes. We recommend moving to msal js for any advanced feature requests and bugfixes.