Customize Third-Party Authentication Sign-On Page (Optional)

If using the Third Party First Authentication Flow option you will want to customize the third-party sign on page to include a link back to the QMS local login page in order to support local QMS login. The link must be to this URL:

  • <your QMS URL>/Account/LocalLogin

The following are instructions to customize the sign-on page in Keycloak (a popular third-party identity provider)

  1. Create a QMS theme directory in the keycloak themes folder, with a login subfolder e.g.
    /themes/qms/login

  2. Copy the base keycloak login theme file into the /themes/qms/login directory and add the following code to the file:

    <#if client.baseUrl??>
    <div class="${properties.kcFormGroupClass!}" style="margin-top:20px">
    <div class="${properties.kcFormOptionsWrapperClass!}">
    <span>If you do not have an account with this Identity Provider, you can login using a local QMS account <a href="${client.baseUrl}/Account/LoginLocal">here</a>.</span>
    </div>
    </div>
    </#if>
  3. Add a theme.properties file to the same /themes/qms/login directory and add the following content to the file:
    parent=keycloak
    import=common/keycloak

  4. Add a base URL to the properties of the client configuration using the keycloak administration pages. The Base URL should be the root URL of your QMS website.