zulip/zproject
Mateusz Mandera 2a1da859ea auth: Update AzureADAuthBackend to use the newer Microsoft API.
As detailed in the comment in the code:

The upstream implementation uses the outdated /oauth2/authorize
API (instead of the v2.0 API), which doesn't allow us to authenticate
users with just a personal Microsoft account. v2.0 API is required.
This requires us to override the default URLs to use it as well
as adjust the requested scopes, to match this new API.

The backend in its previous state was only able to authenticate users
that were tied to an organizational directory, even if the application
settings in Azure were set up to also allow personal accounts. Users
trying to use a personal account would face an error from Microsoft:

AADSTS500200: User account 'xxxx@example.com' is a
personal Microsoft account. Personal Microsoft accounts are not
supported for this application unless explicitly invited to an
organization

https://github.com/python-social-auth/social-core/issues/723 is a
related upstream issue.
2024-08-21 16:16:30 -07:00
..
jinja2 realm-deactivation: Send email to owners as part of deactivation. 2024-06-26 16:48:18 -07:00
__init__.py
backends.py auth: Update AzureADAuthBackend to use the newer Microsoft API. 2024-08-21 16:16:30 -07:00
computed_settings.py saml: Add support for syncing user role. 2024-08-20 11:53:24 -07:00
config.py ruff: Fix UP007 Use `X | Y` for type annotations. 2024-07-13 22:28:22 -07:00
configured_settings.py settings: Print about custom settings from runtornado. 2023-12-05 12:33:34 -08:00
default_settings.py saml: Add support for syncing user role. 2024-08-20 11:53:24 -07:00
dev_settings.py settings: Disable KaTeX server in development. 2024-07-17 17:58:32 -07:00
dev_urls.py dev_urls: Make requests to /docs redirect to the index. 2024-03-21 11:27:14 -07:00
email_backends.py ruff: Fix UP035 Import from `collections.abc`, `typing` instead. 2024-07-13 22:28:22 -07:00
prod_settings.pyi lint: Replace pycodestyle and pyflakes with ruff. 2022-11-03 12:10:15 -07:00
prod_settings_template.py saml: Add support for syncing user role. 2024-08-20 11:53:24 -07:00
sentry.py ruff: Fix UP007 Use `X | Y` for type annotations. 2024-07-13 22:28:22 -07:00
settings.py settings: Hide django_stubs_ext from mypy. 2024-04-17 16:49:03 -07:00
settings_types.py ruff: Fix UP007 Use `X | Y` for type annotations. 2024-07-13 22:28:22 -07:00
template_loaders.py ruff: Fix UP007 Use `X | Y` for type annotations. 2024-07-13 22:28:22 -07:00
test_extra_settings.py tests: Default ENABLE_FILE_LINKS to False. 2024-07-18 13:50:28 -07:00
test_settings.py settings: Refactor how TEST_SUITE is configured. 2023-12-04 09:50:14 -08:00
urls.py user_profile: Remove 'tutorial_status' field. 2024-08-15 13:31:40 -07:00
wsgi.py requirements: Upgrade Python requirements. 2024-01-29 10:41:54 -08:00