What steps will reproduce the problem?
1. Setup LDAP Auth
2. Enable the new realm.ldap.synchronize LDAP Synch option.
3.
What is the expected output? What do you see instead?
Not really sure, but expected that the user accounts would be synched and cleaned up
See java.lang.NullPointerException in logs.
# Defines whether to synchronize all LDAP users and teams into the user service
#
# Valid values: true, false
# If left blank, false is assumed
#
# SINCE 1.4.0
realm.ldap.synchronize = true
2014-03-20 12:34:38 [ERROR] Failed to synchronize with ldap
java.lang.NullPointerException
at com.gitblit.auth.LdapAuthProvider.sync(LdapAuthProvider.java:123)
at com.gitblit.service.LdapSyncService.run(LdapSyncService.java:55)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:744)
2014-03-20 12:34:38 [INFO ] Finished user and group sync with ldap service
What version of the product are you using? On what operating system?
Gitblit 1.4.1 / Centos 6.5
Please provide any additional information below.
Reported by kaosagnt on 2014-03-20 02:00:50
The text was updated successfully, but these errors were encountered:
This is one of those places where improved logging would be useful. :)
There is no "uid" attribute on the returned user search result.
final String username = loggingInUser.getAttribute(uidAttribute).getValue();
logger.debug("LDAP synchronizing: " + username);
# Attribute on the USER record that indicate their username to be used in gitblit
# when synchronizing users from LDAP
# if blank, Gitblit will use uid
# For MS Active Directory this may be sAMAccountName
#
# SINCE 1.0.0
realm.ldap.uid = uid
Originally reported on Google Code with ID 394
Reported by
kaosagnt
on 2014-03-20 02:00:50The text was updated successfully, but these errors were encountered: