[Building Sakai] MultipleEmailLdapAttributeMapper sample
Rosa María Silveira Puertas
rmsilvei at pas.ucm.es
Thu Oct 6 07:45:17 PDT 2011
Hi all,
We have Sakai 2.8 at Universidad Complutense and I'm trying to set jldap-beans.xml to get email for external users from one of these two ldaps attributes: mail or mailAlternateAddress.
At jldap-beans.xml I have this:
<bean id="edu.amc.sakai.user.LdapAttributeMapper"
class="edu.amc.sakai.user.MultipleEmailLdapAttributeMapper"
init-method="init"
singleton="true">
<!-- A typical set of attribute mappings. Keys are logical
names expected by the application. Values are physical LDAP
attribute names. If not specified or empty, defaults to
AttributeMappingConstants.DEFAULT_ATTR_MAPPINGS. -->
<property name="attributeMappings">
<map>
<entry key="login"><value>ucmAuthOwnerID</value></entry>
<entry key="firstName"><value>givenName</value></entry>
<entry key="preferredFirstName"><value>preferredName</value></entry>
<entry key="lastName"><value>sn</value></entry>
<entry key="email"><value>XXXXXXXXXXXXXX</value></entry>
<entry key="groupMembership"><value>groupMembership</value></entry>
<entry key="jpegPhoto"><value>jpegPhoto</value></entry>
</map>
</property>
<!-- Several options for calculating Sakai user types based
on LDAP attributes. Defaults to an instance of EmptyStringUserTypeMapper -->
<property name="userTypeMapper">
<!-- Select one of the following beans -->
<ref bean="edu.amc.sakai.user.EmptyStringUserTypeMapper" />
<!-- ref bean="edu.amc.sakai.user.EntryAttributeToUserTypeMapper" /-->
<!-- ref bean="edu.amc.sakai.user.EntryContainerRdnToUserTypeMapper" /-->
<!-- ref bean="edu.amc.sakai.user.StringUserTypeMapper" /-->
</property>
</bean>
Instead of XXXXXXXXXXXXXXXXXXXXX I have tried with:
· mail,mailAlternateAddress
· mail|mailAlternateAddress
· (mail)(mailAlternateAddress)
· |(mail=*)(mailAlternateAddress=*)
· \(mail=*)(mailAlternateAddress=*)
· .......
And I get this error at tomcat log: WARN http-80-Processor9 edu.amc.sakai.user.JLDAPDirectoryProvider - An error occurred searching for users: com.novell.ldap.LDAPLocalException: (87) Error del filtro
Do you know where I could find some examples of how setting this? Or anyone who could help me if you can't?
Thank you very much in advance and best regards, Rosa
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20111006/c095aa7a/attachment.html
More information about the sakai-dev
mailing list