Hiding Users in eGuide
Novell Cool Solutions: Feature
By Andreas Ollenburg
Digg This -
Posted: 18 Jan 2006
eGuide is a great tool for publishing informations about users. It's easy to set up and easy to use. But when searching for users, you may see some users that should not be visible to others, such as admin users or users used by services.If you have a well-designed tree (for eGuide, that is), you may not run into this problem. But in many cases your design will not fit into the guidelines for eGuide, so you will need a lot of customization to have eGuide running as you want it.
This article discusses one possible easy-to-implement solution on how to hide certain users in eGuide.
I am using the filtering attributes feature in eGuide. Although this is a great feature to use, it has the disadvantage of filtering out only one value per attribute, such as all users whose location is set to "Lummerland." There is also no on-board solution to combine queries. Thus, I wanted a single value to determine whether a user can be seen in eGuide or not.
To do this, I extended the schema by adding an attribute called eGuideStatus of type Boolean. The rule for using this attribute is to set it to False to hide a user in eGuide or True to allow the user to be shown. This can be done by setting a filter on this attribute in the eGuide administration tool, filtering all users where the attribute equals False.
What I needed to do next was to set the attribute for all users; otherwise, no users would be seen in eGuide. This can be done with an LDIF import. For future use, I created an iManager task and added it to the Help desk and User administration roles, where the status of users can be set.
OK, that was the short description. Here comes the detailed part.
First we need to add the new attribute to the schema.
1. Log in to iManager as a user with supervisor rights to [Root].
Figure 1: iManager login, Supervisor rights
2. From the Schema-role select Create attribute, enter a unique attribute name (and a unique ASN1 ID if needed). Click Next.
Figure 2: Creating a unique attribute
3. As the user will either be seen or hidden, a Boolean syntax is perfect for us here. Select it and then click Next.
Figure 3: Boolean syntax
4. The default attribute flags are usually fine, so leave them as they are and click Next.
Figure 4: Default attribute flags
5. Click Finish and OK on the next screen.
Figure 5: Finishing the selection
Now that we have the attribute, we need to add it to the User-class to be able to use it later.
6. Select Add attribute from the Schema-role and User in the Available classes. Then click OK.
Figure 6: x
7. From the list of available attributes, select the attribute you just created and move it to the list of attributes to be added (either by double-clicking or clicking on the left-arrow). Click Next and then OK.
Figure 7: Selecting the attribute
Now your attribute is ready to be used. To manage it through iManager, you will need to set up a task to do so.
8. Select the Configure-icon at the top, open Role-Based Services, and select the Plug-In studio.
Figure 8: Selecting the Plug-in Studio
9. Click New. This will be a task to modify objects of User type, so choose the appropriate selections and click Next.
Figure 9: User type selections
10. From the list of attributes, scroll down to your new attribute and double-click it or drag-and-drop it into the plug-in field. The first icon to the right lets you modify some parameters like the label to be shown in different languages (the default is the name of the attribute). The next icon is to change the control. You can either have a simple check box (by default), two radio buttons for True and False or a drop down field like shown above.
Then, fill in a value for the Plug-in ID which will be used for the name of the task, select the RBS Collection which this task will be installed to and (optionally) the role(s) this task will be added to.
Figure 10: Configuring the task
You can test this right away by going back to the Roles and Task page of iManager and selecting the role you added the task to.
11. Select a user and click OK.
Figure 11: Selecting a user
12. Set the status you want for this user. In the example below, the status is set to False, in order to hide the user admin in eGuide.
Figure 12: Setting the user status
Now it's time to configure eGuide to use the new attribute for filtering.
13. Log in to eGuide as an eGuide administrator and select the Administration utility.
Figure 13: Administration utility
14. Select LDAP Data sources in the left frame and then the data source for the tree you just extended the schema of. If you are using multiple trees for eGuide, you will have to do this procedure for every data source.
Figure 14: Selecting data sources
15. From the Properties column click Edit.
Figure 15: New Data Source screen
16. On the first tab, scroll down to the bottom and select Refresh schema. This will force eGuide to read the list of attributes and classes from the LDAP source again and find your new attribute.
Figure 16: Refreshing the schema
17. Select the tab Attributes and scroll down until your find the new attribute. Click the corresponding More Options link on the right.
Figure 17: Selection options for the new attribute
18. In the pop-up window, check "Enable filtering on this attribute". The search criteria is Equals in our case, and the search value is False.
Figure 18: Attribute filtering
This results in filtering out all objects for which the attribute is set to False. All other objects will be shown.
19. Click Save, close the window and return to the eGuide client interface by selecting the eGuide icon at the top.
You are almost done! Because the attribute has no value for all users who don't have an attribute setting of True or False, these users won't be seen in eGuide either. Thus, you have to set a value for all users using either your new iManager task or an LDIF import. You could also set a default value for the attribute in the schema, but this is advanced schema management and thus beyond the scope of this document.
Remember that you can use filtering in many interesting combinations.
Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com