cancel
Showing results for 
Search instead for 
Did you mean: 

LDAP Synchronization with Alfresco 3.4d

pnavinkumar
Champ in-the-making
Champ in-the-making
Hi all

I am new to alfresco and I am trying to setup the LDAP Sync with 3.4d. I have been able to establish the login to my AD which is a win2003 server. But somehow synchronization doesn't seem to work for me.

Here is my configuration:

authentication.chain=alfrescoNtlm1:alfrescoNtlm,ldap1:ldap-ad

ldap.authentication.active=true
ldap.authentication.userNameFormat=%s
ldap.authentication.defaultAdministratorUserNames=admin
ldap.authentication.java.naming.provider.url=ldap://domainserver:389
ldap.authentication.java.naming.security.authentication=simple

ldap.synchronization.active=true
ldap.synchronization.java.naming.security.principal=ldap@itech.com
ldap.synchronization.java.naming.security.credentials=password

ldap.synchronization.groupQuery=(objectclass\=group)
ldap.synchronization.groupDifferentialQuery=(&(objectclass\=group)(!(modifyTimestamp<\={0})))
ldap.synchronization.personQuery=(objectclass\=inetOrgPerson)
ldap.synchronization.personDifferentialQuery=(&(objectclass\=inetOrgPerson)(!(modifyTimestamp<\={0})))
ldap.synchronization.groupSearchBase=ou\=Groups,dc\=itech,dc\=com
ldap.synchronization.userSearchBase=CN\=Users,dc\=itech,dc\=com
ldap.synchronization.modifyTimestampAttributeName=modifyTimestamp
ldap.synchronization.timestampFormat=yyyyMMddHHmmss'Z'

ldap.synchronization.userIdAttributeName=sAMAccountName
ldap.synchronization.userFirstNameAttributeName=givenName
ldap.synchronization.userLastNameAttributeName=sn
ldap.synchronization.userEmailAttributeName=mail
ldap.synchronization.userOrganizationalIdAttributeName=o
ldap.synchronization.defaultHomeFolderProvider=userHomesHomeFolderProvider
ldap.synchronization.groupIdAttributeName=cn
ldap.synchronization.groupType=groupOfNames
ldap.synchronization.personType=inetOrgPerson
ldap.synchronization.groupMemberAttributeName=member


but the above configuration fails with the below error:

15:46:40,220 UserSmiley Frustratedystem ERROR [security.sync.ChainingUserRegistrySynchronizer] Synchronization aborted due to error
org.alfresco.error.AlfrescoRuntimeException: 03040000 User and group import failed

Caused by: javax.naming.NameNotFoundException: [LDAP: error code 32 - 0000208D: NameErr: DSID-031001CD, problem 2001 (NO_OBJECT), data 0, best match of:
'DC=itech,DC=com'
]; remaining name 'ou=Groups,dc=itech,dc=com'


Desperately looking for help on this. Hoping to get a response.

Thanks in advance.
20 REPLIES 20

goingcrazy
Champ in-the-making
Champ in-the-making
I too would like to know how to get LDAP synch to work- However I am using my CAS server for authentication… but I do wish to have my LDAP synching with Alfresco for the users

pnavinkumar
Champ in-the-making
Champ in-the-making
Members

Can anyone let me know a solution to this? I have been searching around for quite some time for a working solution but still haven't been able to figure out one.

Thanks for the help.

Navin

mouradef
Champ in-the-making
Champ in-the-making
Hi,
Did you resolve your problem ?
you still need help ?

mouradef
Champ in-the-making
Champ in-the-making
Hi,
Did you resolve your problem ?
you still need help ?

pnavinkumar
Champ in-the-making
Champ in-the-making
Hi

I haven't been able to get this resolved yet. Your help on this will be great. As I have told, I have been able to successfully login to the application using my AD credentials. But unable to synchronize the user and group info from AD LDAP.

Let me know if you would need any more info.

Thanks

mouradef
Champ in-the-making
Champ in-the-making
Hi,
I had the same problem before, LDAP connection was OK but i was unable to make full synchro
I resolved this by putting the following synchronization options in alfresco-globals.properties
synchronization.import.cron=15 * * * * ?
synchronization.synchronizeChangesOnly=false
synchronization.syncOnStartup=false


my experience is that these options are not taken into account when put in ldap-ad-authentification.properties.

ps: these options are for test purpose, to make full synchro every minute at 15 seconds, you certainly should tune it for your need

Tell me what do you think about this. Thanks.

pnavinkumar
Champ in-the-making
Champ in-the-making
Hi

I tried providing these settings on the alfresco.global properties file. But still i didn't work out for me. Can you share the ldap.synchronization settings that you had used with me?

Thanks

schulman
Champ in-the-making
Champ in-the-making
Hello,

I would change this :
ldap.synchronization.groupType=groupOfNames
by
ldap.synchronization.groupType=group

And
ldap.synchronization.timestampFormat=yyyyMMddHHmmss'Z'
by
ldap.synchronization.timestampFormat=yyyyMMddHHmmss'.0Z'

as mentionned here : http://wiki.alfresco.com/wiki/Alfresco_Authentication_Subsystems

mouradef
Champ in-the-making
Champ in-the-making
Hello,
this is my ldap-ad.properties file, located in: …subsystems/authetification/ldap-ad

# This flag enables use of this LDAP subsystem for authentication. It may be

# that this subsytem should only be used for synchronization, in which case

# this flag should be set to false.

ldap.authentication.active=true



#

# This properties file brings together the common options for LDAP authentication rather than editing the bean definitions

#

ldap.authentication.allowGuestLogin=true



# How to map the user id entered by the user to taht passed through to LDAP

# In Active Directory, this can either be the user principal name (UPN) or DN.

# UPNs are in the form <sAMAccountName>@domain and are held in the userPrincipalName attribute of a user

ldap.authentication.userNameFormat=%s@yourDomain



# The LDAP context factory to use

ldap.authentication.java.naming.factory.initial=com.sun.jndi.ldap.LdapCtxFactory



# The URL to connect to the LDAP server

ldap.authentication.java.naming.provider.url=ldap://yourServer



# The authentication mechanism to use for password validation

ldap.authentication.java.naming.security.authentication=simple



# Escape commas entered by the user at bind time

# Useful when using simple authentication and the CN is part of the DN and contains commas

ldap.authentication.escapeCommasInBind=false



# Escape commas entered by the user when setting the authenticated user

# Useful when using simple authentication and the CN is part of the DN and contains commas, and the escaped \, is

# pulled in as part of an LDAP sync

# If this option is set to true it will break the default home folder provider as space names can not contain \

ldap.authentication.escapeCommasInUid=false



# Comma separated list of user names who should be considered administrators by default

ldap.authentication.defaultAdministratorUserNames=Administrator



# This flag enables use of this LDAP subsystem for user and group

# synchronization. It may be that this subsytem should only be used for

# authentication, in which case this flag should be set to false.

ldap.synchronization.active=true



# The authentication mechanism to use for synchronization

ldap.synchronization.java.naming.security.authentication=simple



# The default principal to bind with (only used for LDAP sync). This should be a UPN or DN

ldap.synchronization.java.naming.security.principal=cn\=****,OU\=****,OU\=***,DC\=****,DC\=**



# The password for the default principal (only used for LDAP sync)

ldap.synchronization.java.naming.security.credentials=****



# If positive, this property indicates that RFC 2696 paged results should be

# used to split query results into batches of the specified size. This

# overcomes any size limits imposed by the LDAP server.

ldap.synchronization.queryBatchSize=1000



# If positive, this property indicates that range retrieval should be used to fetch

# multi-valued attributes (such as member) in batches of the specified size.

# Overcomes any size limits imposed by Active Directory.      

ldap.synchronization.attributeBatchSize=1000



# The query to select all objects that represent the groups to import.

ldap.synchronization.groupQuery=(objectclass\=group)



# The query to select objects that represent the groups to import that have changed since a certain time.

ldap.synchronization.groupDifferentialQuery=(&(objectclass\=group)(!(modifyTimestamp<\={0})))



# The query to select all objects that represent the users to import.

ldap.synchronization.personQuery=(&(objectclass\=user)(userAccountControl\:1.2.840.113556.1.4.803\:\=512))



# The query to select objects that represent the users to import that have changed since a certain time.

ldap.synchronization.personDifferentialQuery=(&(objectclass\=user)(userAccountControl\:1.2.840.113556.1.4.803\:\=512)(!(modifyTimestamp<\={0})))



# The group search base restricts the LDAP group query to a sub section of tree on the LDAP server.

#ldap.synchronization.groupSearchBase=CN=*****,OU=******,OU=****,OU=***,DC=***,DC=**

ldap.synchronization.groupSearchBase=OU=******,OU=****,OU=***,DC=***,DC=**


# The user search base restricts the LDAP user query to a sub section of tree on the LDAP server.

#users found in group search must belong to this userSearchBase

ldap.synchronization.userSearchBase=OU=**** , *****,OU=***,DC=****,DC=**





# The name of the operational attribute recording the last update time for a group or user.

ldap.synchronization.modifyTimestampAttributeName=modifyTimestamp



# The timestamp format. Unfortunately, this varies between directory servers.

ldap.synchronization.timestampFormat=yyyyMMddHHmmss'.0Z'



# The attribute name on people objects found in LDAP to use as the uid in Alfresco

ldap.synchronization.userIdAttributeName=sAMAccountName



# The attribute on person objects in LDAP to map to the first name property in Alfresco

ldap.synchronization.userFirstNameAttributeName=givenName



# The attribute on person objects in LDAP to map to the last name property in Alfresco

ldap.synchronization.userLastNameAttributeName=sn



# The attribute on person objects in LDAP to map to the email property in Alfresco

ldap.synchronization.userEmailAttributeName=mail



# The attribute on person objects in LDAP to map to the organizational id  property in Alfresco

ldap.synchronization.userOrganizationalIdAttributeName=company



# The default home folder provider to use for people created via LDAP import

ldap.synchronization.defaultHomeFolderProvider=userHomesHomeFolderProvider



# The attribute on LDAP group objects to map to the authority name property in Alfresco

ldap.synchronization.groupIdAttributeName=cn



# The attribute on LDAP group objects to map to the authority display name property in Alfresco

ldap.synchronization.groupDisplayNameAttributeName=displayName



# The group type in LDAP

ldap.synchronization.groupType=group



# The person type in LDAP

ldap.synchronization.personType=user



# The attribute in LDAP on group objects that defines the DN for its members

ldap.synchronization.groupMemberAttributeName=member



# If true progress estimation is enabled. When enabled, the user query has to be run twice in order to count entries.

ldap.synchronization.enableProgressEstimation=true