Create new user in Keycloak

To use applications that use Keycloak for authentication and authorization, we need a user to log in. Usually, in large systems, the user information will be stored in Active Directory (AD) or LDAP, Keycloak can connect to these systems to retrieve user information. It can also store user information directly. In this tutorial, I will show you how to create a new user in Keycloak!

First, you need to login to Keycloak with your admin account, then select the Users menu item on the left. The Users page contents will display as follows:

Create new user in Keycloak

By default, the list of users included in Keycloak will not be displayed at all. Perhaps it is because maybe the Keycloak developers are in case there are too many users in Keycloak, it is not necessary to load all users by default. You can use the Search box to find the user information you want.

Here Keycloak also has an option that allows us to view a list of all users. By clicking the View all users button, you will see the following results:

Create new user in Keycloak

You can also unlock users in Keycloak using the Unlock users button and to add a new user, click the Add user button.

Create new user in Keycloak

ID and Create At information will be generated when you click the Save button to save the new user information.

Username is the username used to log in.

Email is the email of the user.

First Name and Last Name are the names of the user.

You can enable or disable the user using the User Enabled box with the value ON or OFF.

Email Verified allows us to verify that a user’s email has been verified or not? ON is verified and OFF is not yet!

Required User Actions defines a number of actions:

Create new user in Keycloak

if you want, you can choose to let the user do it.

After filling in the information, you can click the Save button to complete the new creation.

My example is as follows:

Create new user in Keycloak

Result:

Create new user in Keycloak

To update the login password, go to the Credentials tab in this window:

Create new user in Keycloak

Please enter the Password and Password Confirmation.

If this is only a temporary password, the user needs to change the password when logging in, then leave the Temporary box default with the value ON, otherwise, turn it OFF.

Finally, you press the Set Password button to save this password. The following window will appear:

Create new user in Keycloak

to confirm that you really want to set a password for this user.

Keep pressing the Set password button to confirm!

Result:

Create new user in Keycloak

At this point, you can use this user to log into your application already!

Chia sẽ bài viết này ...Share on Facebook
Facebook
0Tweet about this on Twitter
Twitter
Share on LinkedIn
Linkedin

Add Comment