Setting up a one-time password policy as MFA in Keycloak
As a Server Administrator, you can set up a one-time password (OTP) authentication policy in Keycloak as part of the multi-factor authentication (MFA) to validate the authenticity of the users when they sign in or log into HCL OneTest™ Server.
Before you begin
- Ensured that you are assigned a role as a Server Administrator of HCL OneTest™ Server. See Default user administration.
- Installed HCL OneTest™ Server. See Installation of the server software.
- Configured the licenses for HCL OneTest™ Server. See HCL license portal.
About this task
Keycloak provides an OTP policy that can be enabled and configured in Keycloak for the installed instance of HCL OneTest™ Server. You can refer to the Keycloak documentation about the OTP policies.
Procedure
- Log in to HCL OneTest™ Server, if you are not already logged in.
-
Open Keycloak by entering /auth in the Address
bar after the URL of your server instance, and then press the
Enter key.
For example, if the URL of the server instance is https://<myserver.mycompany.com>, add /auth after the URL as in https://<myserver.mycompany.com>/auth
The Keycloak dashboard is displayed. - Click Administration Console.
-
Log into the Keycloak administration console by using the default username as
keycloak and the password generated for you by Keycloak,
if prompted.
The Keycloak console is displayed.
-
Change the realm to testserver, if it is not already in this
realm.
The testserver realm dashboard is displayed.
-
Click Authentication in the navigation pane.
The Authentication page is displayed.
-
Click the Policies tab, and then click the
OTP Policy tab.
The OTP Policy configuration settings are displayed.
-
Read the description provided for each of the fields by clicking and decide the values that you want to set for each of the fields,
which are different from the default values listed.
You can save the changed configuration or use the default configuration without making any changes.
Results
You configured the settings or retained the default settings for an OTP policy in Keycloak.
What to do next
You must enable the OTP policy in Keycloak as the default option for authentication. See Enabling the one-time password policy as the default MFA action in Keycloak.