How to enable Auto Azure AD SSO login for internal users + optional login page for backend users

0
Hi everyone, I have a Mendix app intended only for internal company users. Azure AD SSO is configured using the OIDC module and currently works via a “Login via SSO” button on a custom login page. Requirement: When users open the app URL, they should be automatically logged in via Azure AD SSO (no login page). If someone explicitly opens /login.html, they should land on the custom/default login page, where an alternative login method is available for a very limited set of backend users. Questions: Can the OIDC SSO flow be auto-triggered on app load? Is it possible to bypass the login page by default, but still allow access to it via /login.html? What is the recommended/best-practice approach for this kind of setup in Mendix? Thanks in advance!
asked
1 answers
0

Hi Neha,

Yes, it is possible to redirect users when the base URL is hit for both OIDC and SSO.

pls refer below 

image.png

 

documentation link - Redirect SSO 

This configuration will redirect users on both when base URL or  login.html  is hit

Custom Login Page Setup

In your case, if you want to use a custom login page, you can use either:

  • loginlocal.html, or

  • login3.html

For this to work, you also need a corresponding custom index page (index3.html).

How the Redirection Works

  • By default, after successful authentication, login.html redirects users to index.html.

  • For a custom login (loginlocal.html or login3.html), after successful authentication, users will be redirected to index3.html.

Steps to Configure

  1. Duplicate login.html located at:project folder > theme > web(If not found there, check deployment > web)

  2. Rename the duplicated file to loginlocal.html or login3.html, and add your custom login HTML.

  3. Duplicate index.html and rename it to index3.html.

After these steps, your folder structure under theme > web will look like this:

image.png

 

 

let me know if any questions

 

Regards

 

 

answered