Legacy Knowledge Base
Published Jul. 2, 2025

How to Redirect to OpenID Connect Page after clicking the "Sign In" Button

Written By

Gábor Komáromi

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.

Issue

  • The steps users take to login via OpenID Connect are very long. They have to:
    1. Click the "sign in" button on the home page
    2. The Sign-In Portlet comes up
    3. Click on "OpenID Connect" link
    4. Choose the OpenID Identity Provider
    5. Click on "Sign In" button of the Sign-In Portlet, before they are redirected to the Identity Provider's Sign In Page.
  • How can we shorten this process to just get to the Identity Provider's Sign In Page after the first click on the sign-in button?

Environment

  • Liferay DXP 7.2
  • OpenID Connect Protocol

Resolution

  • There are no default options available which may minimize the steps involved in the process required before a user is sent to the OpenID Connect provider.
  • However, there is a workaround by modifying the portal-ext.properties:
    Enter a URL that will be used to login portal users whenever needed. By default, the portal's login page is used.

    Env: LIFERAY_AUTH_PERIOD_LOGIN_PERIOD_URL

    Examples:
        auth.login.url=/web/guest/home
    to:
    Enter a URL that will be used to login portal users whenever needed. By default, the portal's login page is used.

    Env: LIFERAY_AUTH_PERIOD_LOGIN_PERIOD_URL

    Examples:
        auth.login.url=/home/-/login/openid_connect_request?p_p_state=maximized&_com_liferay_login_web_portlet_LoginPortlet_saveLastPath=false&_com_liferay_login_web_portlet_LoginPortlet_redirect=/&_com_liferay_login_web_portlet_LoginPortlet_OPEN_ID_CONNECT_PROVIDER_NAME=IAM
    IAM stands for the Provider Name entered under System Settings > SSO > OpenID Connect Provider.
    /home stands for your home page's friendly URL. By default, it is /home.
  • This way, after clicking on Sign In, the user will be automatically redirected to the Identity Provider's Sign In Page.
Did this article resolve your issue ?

Legacy Knowledge Base