1

On my WSS server I have run the following stsadm command to filter the people picker results:

stsadm.exe -o setproperty -url http://myserver -pn "peoplepicker-searchadcu stomfilter" -pv "(memberOf=CN=SharePoint,OU=AccessGroups,DC=contosio,DC=local)"

My WSS sites are all used by different groups of users.

Whenever I create a new site collection in WSS I want to ensure that I can filter the people picker to only show he relevant users for that group - can I automate this or would I have to manually do something like the above stsadm command?

All the best

78lro
  • 1,790
  • 7
  • 37
  • 63

2 Answers2

0

You could implement a SPWebProvisioningProvider this is a piece of code which can be run when a new site (based on a specific site definition) is created.

You would need to ensure that your site collection root was using the appropriate site definition.

More info can be found here.

You would need to either implement your stsadm call using the object model, or else wrap the specific call to that command in some custom code.

Charlie
  • 2,096
  • 2
  • 22
  • 34
0

Unfortunately, peoplepicker-searchadcustomfilter applies to the entire web application, even if I specify a site collection in the URL parameter.

stsadm –o setproperty –propertyname peoplepicker-searchadcustomfilter -propertyvalue "(|(userPrincipalName=*mycompany.com)(memberof=CN=client_users,OU=client_Users,OU=Extranet,DC=client,DC=int))" -url http://myserver/sites/site1 

stsadm -o getproperty -pn peoplepicker-searchadcustomfilter -url http://myserver/sites/site1
stsadm -o getproperty -pn peoplepicker-searchadcustomfilter -url http://myserver/sites/site2

When I ran the above, I expected to see site1 with the custom LDAP query, and site2 with no filter applied. But instead I see the custom LDAP query on all site collections in this web application. Bummer.

Looks like Microsoft needs to clarify the documentation.

dirq
  • 968
  • 2
  • 11
  • 26