LDAP Active Directory Sync User

Hello,

I succesfully setup Xwiki Enterprise 9.4 with ldap plugin. In my environment, I setup my xwiki to authenticate on Active Directory LDAP ( run perfectly !). How do you do to have all sync users From Active Directory to xwiki database ? Target is to add Active Directory LDAP’s user to local group on xwiki.

Thank You for your help and Regards

Hello,

Please give to me advise

Regards

Hello,
xwiki account is created at first login but you can use this setting to map xwiki groups to LDAP groups:

You can check this settings too:

#-# Time in s after which the list of members in a group is refreshed from LDAP
#-# The default is 21600 (6 hours)
xwiki.authentication.ldap.groupcache_expiration=86400

#-# [Since 1.3M2, XWikiLDAPAuthServiceImpl]
#-# - create : synchronize group membership only when the user is first created
#-# - always: synchronize on every login
#-# The default is always
# xwiki.authentication.ldap.mode_group_sync=always

Pascal B

There is not built in synchronization of users.

If your concern is authorization what we usually do is setup all required authorizations using XWiki groups and configure the authenticator to automatically put the users in the right groups when they login as suggested by @Pbas.

If your need is to actually have a list of all users (for people to have contacts of each other for example) and you are afraid that some of them might never login then you’ll need to write a Groovy script (or a Java module) using not very documented APIs involving classes located on ldap/ldap-authenticator/src/main/java/org/xwiki/contrib/ldap at master · xwiki-contrib/ldap · GitHub (mostly XWikiLDAPConfig, XWikiLDAPUtils and XWikiLDAPConnection and look at ldap/ldap-authenticator/src/main/java/org/xwiki/contrib/ldap/XWikiLDAPAuthServiceImpl.java at master · xwiki-contrib/ldap · GitHub for how to initialize them).

Don’t know if it’s an option for you but I think that the XWiki SAS company has done this kind of work in the past for its customers (and if not, I’m sure they could do it) so you might also want to request a quote from their professional services, see https://www.xwiki.org/xwiki/bin/view/Main/Support#HProfessionalSupport (or from any other listed company!).

Hello,

Thank you very much all for your time and replies. I used Xwiki authentication method by group

Regards