Search Results :

×

Automatic User Provisioning and Sync between Joomla and Keycloak


Keycloak User Sync is an easy-to-use plugin for Joomla to facilitate the synchronization of user data between Keycloak, an identity management platform, and Joomla. This plugin uses the Keycloak Rest API to fetch all the user's profiles from Keycloak to the Joomla database. Seamless support for advanced sync features like bi-directional user sync, automatic user creation & deletion, group mapping, and many more. It provides a simple and secure way to keep user information in sync, allowing administrators to provision users and manage user data with manual, on-demand, or scheduler-based provisioning.

Pre-requisites : Download And Installation

Steps to Setup Keycloak user sync for Joomla

1. Install the Keycloak User Sync for Joomla

  • Download the zip file for the miniOrange User Provisioning/User Sync plugin from the link here .
  • Login into your Joomla site’s administrator console.
  • From Menu, click on System, then under Install section click on Extensions.
  • Upload the downloaded zip file to install the User Provisioning/User Sync plugin.
  • Installation of the plugin is successful. Now click on Get Started! button.
  • Joomla Keycloak User Sync
  • Select 'Keycloak' from the list of providers.
  • Joomla Keycloak User Sync

2. Configure Keycloak

  • Go to your Keycloak console and select your realm and click on Users. Ensure that your Realm does not have a space present in the name.
  • Configure Keycloak user sync plugin
  • Go to Users and click on the Create new user button to create a user.
  • Configure Keycloak user sync plugin
  • On creating a new user enter the required details and click on Create.
  • Configure Keycloak user sync plugin
  • After a user is created go to Credentials tab and click on the Set password button to set a password for the user.
  • Configure Keycloak user sync plugin
  • Enter the user password and click on Save.
  • Configure Keycloak user sync plugin
Note: Disabling Temporary will make user password permanent.

  • Once the user password is set, go to the Role Mapping tab and assign the user a role of ‘manage-users’ under the ‘realm-management’ client roles.
  • Configure Keycloak user sync plugin
  • Filter the roles by Filter by clients and search by user, select the realm-management, manage-users role and click on the Assign button.
  • Configure Keycloak user sync plugin

3. Create a Client

  • To create a client click on the Clients section on the left panel and click on the Create Client button.
  • Configure Keycloak user sync plugin
  • To create the client, enter the required details and click on the Next button.
  • Configure Keycloak user sync plugin
Note: The Client ID should not have any spaces between.

  • In the next step, select only the Direct access grant type and click on the Save button.
  • Configure Keycloak user sync plugin
  • All the configurations are completed on the Keycloak side. Let’s go to our Joomla Keycloak sync plugin and complete the plugin configuration.

4. Configure Keycloak User Sync Plugin

  • Go to the Configure Keycloak tab and enter the Keycloak Domain, Client ID and your Realm name from the Keycloak application that you created above.
  • To copy the Keycloak domain, go to your Keycloak console and copy the domain.
  • Configure Keycloak user sync plugin
  • Enter the copied Keycloak domain name in the Keycloak Domain field present on the Configure Keycloak tab.
  • Configure Keycloak user sync plugin
  • To copy the Client ID hover to your Keycloak settings and copy the client ID from there as shown below.
  • Configure Keycloak user sync plugin
  • Copy the Client ID and paste it in the Client ID field in the Configure Keycloak tab.
  • Configure Keycloak user sync plugin
  • To copy the Realm name go to your Keycloak panel and copy the realm name.
  • Configure Keycloak user sync plugin
  • Then paste it in the Realm field in the Configure Keycloak tab.
  • Configure Keycloak user sync plugin
  • Enter the Username and the password of the user you created with the permission of ‘manage-users’ and click on the Save Configuration button.
  • Configure Keycloak user sync plugin
  • Congratulations, you have successfully verfied the User's Email address during registartion.

5. Test Configuration

  • To test if the connection is successful or not, click on the Test Connection button present in the Configure Keycloak tab.
  • Configure Keycloak user sync plugin

6. Sync User to Joomla Database

  • Navigate to the tab Keycloak -> Joomla. Under the User Attribute Mapping section map the Keycloak attribute name to the respective Joomla attribute Name and click on Save Configuration.
  • Keycloak user sync with Joomla - User Attribute Mapping
miniorange img  Sync an Individual User or All Users
  • Enter UserPrincipleName / ID of any user of your Keycloak application.
  • Click on the Create User button to create your Keycloak user to your Joomla site Database.
  • Or click on the Create All Users button to sync all users from the Keycloak users to your Joomla site Database. (Note: This is a Premium Feature.)
  • Keycloak user sync with Joomla - testconfig
miniorange img  Sync User Groups (Premium Feature)
  • Under the Sync User Groups, you can map user groups from Keycloak to Joomla user groups. Also, select default group for the new/login users.
  • Keycloak user sync with Joomla - Sync Groups
miniorange img  Set User Sync Interval (Premium Feature)
  • Under Set User Sync Interval section, set up a schedule for automatic user synchronization on a hourly, daily, or weekly basis.
  • Keycloak user sync with Joomla - Sync Interval

7. Sync User from Joomla Database to Keycloak

miniorange img  Create and Delete User
  • Navigate to the tab Joomla -> Keycloak. Here, under the Create an Individual User section, any user created in Joomla will sync automatically and get created in Keycloak.
  • Under the Delete User section, you can delete an individual user from Keycloak.
  • Keycloak user sync with Joomla - Create User
miniorange img  Automatic Provisioning (Premium Feature)
  • Under the Automatic Provisioning section, you can automate provisioning whenever a user is created, deleted and updated. You can also enable automatic sync of Joomla user password.
  • Keycloak user sync with Joomla - Automatic Provisioning
miniorange img  Sync User Attributes and Set Interval (Premium Feature)
  • Under the Sync User Attribute tab, you can map user attributes from Joomla to Keycloak.
  • You can also set up a schedule for automatic user synchronization, under the Set User Sync Interval tab.
  • Keycloak user sync with Joomla - Set Attribute

You have successfully configured Keycloak User Sync with Joomla. If you are looking for anything which you cannot find, please drop us an email on joomlasupport@xecurify.com.

Additional Resources

Hello there!

Need Help? We are right here!

support
Contact miniOrange Support
success

Thanks for your inquiry.

If you dont hear from us within 24 hours, please feel free to send a follow up email to info@xecurify.com