Vue combinée Vue Plate Arborescence
Sujets [ Précédent | Suivant ]
toggle
Henrik Alstad
LDAP export, error when creating new user
7 octobre 2013 01:46
Réponse

Henrik Alstad

Rang: New Member

Publications: 4

Date d'inscription: 7 octobre 2013

Publications Récentes

Hi.
I'm using OpenDS 2.2.1, and Liferay Portal Community Edition 6.1.1 CE GA2.
I have turned on export to LDAP, and everything works smoothly, except that if I log in with the liferay admin, and create new users, I get the message:
1"Users and Organizations is temporarily unavailable. "

in the UI of the admin control panel.

The tomcat log shows:
1
20:36:42,768 ERROR [http-bio-8082-exec-3][render_portlet_jsp:154] java.lang.NullPointerException
3    at com.liferay.portal.security.pwd.PasswordPolicyToolkit.generateDynamic(PasswordPolicyToolkit.java:164)
4    at com.liferay.portal.security.pwd.PasswordPolicyToolkit.generate(PasswordPolicyToolkit.java:76)
5    at com.liferay.portal.security.pwd.ToolkitWrapper.generate(ToolkitWrapper.java:32)
6    at com.liferay.portal.security.pwd.PwdToolkitUtil.generate(PwdToolkitUtil.java:29)


However, the LDAP logs show no sign of trouble(as far as I can see):
 1
 2[04/Oct/2013:17:17:59 +0200] SEARCH REQ conn=27 op=27 msgID=28 base="dc=test,dc=example,dc=com" scope=wholeSubtree filter="(&(uid=asd)(objectClass=person))" attrs="ALL"
 3[04/Oct/2013:17:17:59 +0200] SEARCH RES conn=27 op=27 msgID=28 result=0 nentries=0 etime=0
 4[04/Oct/2013:17:17:59 +0200] SEARCH REQ conn=28 op=6 msgID=7 base="dc=test,dc=example,dc=com" scope=wholeSubtree filter="(&(uid=asd)(objectClass=person))" attrs="ALL"
 5[04/Oct/2013:17:17:59 +0200] SEARCH RES conn=28 op=6 msgID=7 result=0 nentries=0 etime=1
 6[04/Oct/2013:17:17:59 +0200] SEARCH REQ conn=28 op=7 msgID=8 base="dc=test,dc=example,dc=com" scope=wholeSubtree filter="(&(uid=asd)(objectClass=person))" attrs="ALL"
 7[04/Oct/2013:17:17:59 +0200] SEARCH RES conn=28 op=7 msgID=8 result=0 nentries=0 etime=0
 8[04/Oct/2013:17:17:59 +0200] ADD REQ conn=27 op=28 msgID=29 dn="uid=asd,ou=People, dc=test, dc=example, dc=com"
 9[04/Oct/2013:17:17:59 +0200] ADD RES conn=27 op=28 msgID=29 result=0 etime=9
10[04/Oct/2013:17:17:59 +0200] SEARCH REQ conn=28 op=8 msgID=9 base="dc=test,dc=example,dc=com" scope=wholeSubtree filter="(&(uid=asd)(objectClass=person))" attrs="ALL"
11[04/Oct/2013:17:17:59 +0200] SEARCH RES conn=28 op=8 msgID=9 result=0 nentries=1 etime=1
12[04/Oct/2013:17:17:59 +0200] MODIFY REQ conn=27 op=29 msgID=30 dn="uid=asd,ou=People,dc=test,dc=example,dc=com"
13[04/Oct/2013:17:17:59 +0200] MODIFY RES conn=27 op=29 msgID=30 result=0 etime=2
14[04/Oct/2013:17:18:00 +0200] SEARCH REQ conn=28 op=9 msgID=10 base="dc=test,dc=example,dc=com" scope=wholeSubtree filter="(&(uid=asd)(objectClass=person))" attrs="ALL"
15[04/Oct/2013:17:18:00 +0200] SEARCH RES conn=28 op=9 msgID=10 result=0 nentries=1 etime=1


Also, when I log out of liferay, and I check OpenDS/LDAP, the created user is indeed exported from liferay and imported to LDAP,
and the user can then log in to liferay.
So why is this error showing up, and how can I get rid of it?
Henrik Alstad
RE: LDAP export, error when creating new user
9 octobre 2013 03:31
Réponse

Henrik Alstad

Rang: New Member

Publications: 4

Date d'inscription: 7 octobre 2013

Publications Récentes

I found that by disabling "Use LDAP Password Policy", the error is gone.
(However, this changes the way liferay exports password changes to LDAP, so it's not a solution.

In case it's not clear, this is the behaviour I want:
- Create a user in Liferay
- Edit the users password
- This user should now exist both in Liferay and LDAP, with the users password being the same on liferay and LDAP.

I'm guessing the error occurs because, when exporting a newly created user(in liferay) to LDAP, it has yet to receive a password, since in liferay you don't specify passwords at the same time as you create a user, and that somehow this results in a null-pointer exception and failure to re-import the user from LDAP to Liferay.
Does anyone know if this is the case? Is there anything I can do in configuration such as settings, or filters in web.xml etc, to make this work as expected?