Specifically I am referring to the and it’s new feature called “Custom Filters” that was added in the latest version 1.0.3 rev.111005

Some customers were asking for it, so here is what you can do now.

Imagine the following scenario.

  1. You have a pretty massive AD, let’s say 50K objects in this OU:

<add name="usa" connectionString="LDAP://ADServer/OU=Many Users,DC=usa,DC=sitecore,DC=net" 

  1. You want to have only a certain number of users to be able to access Sitecore. Plus you want to control such access on AD level by membership to a specific group, let’s say “Sitecore Devs”.

Since your users may belong to multiple OUs as shown below:

SNAGHTMLbd083bd

…what you have to do previously is pull in all 50K users by AD Membership Provider, which was obviously not pretty.

What you can do now is setup a custom filter by querying memberOf, for example:

<add name="usa" 
 type="LightLDAP.SitecoreADMembershipProvider" 
 connectionStringName="usa"
 applicationName="sitecore"
 blablabla
 customFilter="(memberOf=cn=Sitecore Devs,OU=Roles,OU=Many Users,DC=usa,DC=sitecore,DC=net)" />

image

As a result, only 3 users show up in my User Manager:

image

More on this can be found in Section 4.1 of this official Sitecore document

Enjoy!