New features for the LDAP Provider in Sakai

I’ve just completed work on a set of modifications to the LDAP Provider in Sakai, which should be of interest to anyone that has an LDAP integration,  as it adds some nifty features:

1. Use a preferred name if it exists:
http://jira.sakaiproject.org/browse/SAK-17238

This adds an additional field to the jldap-beans.xml config file called preferredFirstName, which if set, will map the value of that field onto the firstName field preferentially. So if you have a preferredName field in your LDAP directory, that value can pass through into Sakai.

2. Searching an LDAP server given some criteria:
http://jira.sakaiproject.org/browse/SAK-18288

This leverages a new kernel interface called ExternalUserSearchUDP added as part of SAK-6792 which allows searching of an external directory, for matches in either username, email, first name or last name.
JLDAP provider now implements this interface and will search the directory for users that match the criteria. This is exposed in the UserDirectoryService as searchExternalUsers(String criteria, int first, int last).

3. Finding users who share an email address:
http://jira.sakaiproject.org/browse/SAK-17922

This leverages a new kernel interface called UsersShareEmailUDP which allows searching of an external directory for multiple users who share the same email address. The UserDirectoryService already takes advantage of this via the findUsersByEmail(String email) method, however the provider was only returning one entry. With this extension, the provider can now return the full set of matches.

4. Adding a jpegPhoto property to a User’s properties:
http://jira.sakaiproject.org/browse/SAK-17816

This adds an additional field to the jldap-beans.xml config file called jpegPhoto, which if set, will map the value of that field to a corresponding property in the User object, containing a BASE-64 encoded JPEG image. Some directory providers add official images to this field for their users, so this will allow a central store of these images.
This will then feed into Profile2, so these official images can be used preferentially.

Comments and feedback welcome.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s