AzureAD / microsoft-authentication-library-for-python

Microsoft Authentication Library (MSAL) for Python makes it easy to authenticate to Microsoft Entra ID. General docs are available here https://learn.microsoft.com/entra/msal/python/ Stable APIs are documented here https://msal-python.readthedocs.io. Questions can be asked on www.stackoverflow.com with tag "msal" + "python".
https://stackoverflow.com/questions/tagged/azure-ad-msal+python
Other
770 stars 192 forks source link

Feature request: Provide the possibility to use a webview instead of the system browser. #438

Closed CmdrRikr closed 8 months ago

CmdrRikr commented 2 years ago

Feature description
In the msal for C# it is possible to use a embedded webview instead
of the system browser for sign in (at least for android and ios devices).

It would be very useful to have this feature in the python libary too in order
to provide more control over the signin window behavior.

rayluo commented 2 years ago

What platform are you referring to? Python is generally not used on Android and iOS devices.

If you mean to say Windows platform, it is true that MSAL for C# can still use an embedded webview. But then, what kind of "more control" do you have in mind? Can you elaborate? We would want to make sure we fully understand your expectation.

CmdrRikr commented 2 years ago

With more control I have in mind that I want the confirmation message to be separable from the login process. Currently this confirmation message is opened in a separate tab. Being able to inform about a successful login within my own application would be helpful or not show the message at all and instead fail if the login was not successful. It would also be helpful to be able to close the confirmation message from within my application without closing the system browser.

rayluo commented 2 years ago

Thanks for explaining. By the way, what is the platform your app runs on? Is it a desktop GUI app or a command line script?

CmdrRikr commented 2 years ago

The app runs on Windows. Msal for python is used in a own library without a GUI. The app which uses this library has a GUI.

rayluo commented 8 months ago

MSAL Python 1.25 supports using a broker which came with Windows 10+. That can accomplish what you need. You can refer to this sample for interactive login.