18.6. slapi_search_internal_set_pb()
SLAPI_TARGET_DNset to the DN that allows to select the right backend.SLAPI_TARGET_UNIQUEIDset to the unique ID of the entry.
SLAPI_TARGET_DNset to the search base.SLAPI_SEARCH_SCOPEset to the search scope.SLAPI_SEARCH_STRFILTERset to the search filter.SLAPI_CONTROLS_ARGset to request controls, if present.SLAPI_SEARCH_ATTRSset to the list of attributes to return.SLAPI_SEARCH_ATTRSONLYindicates whether attribute values should be returned.
#include "slapi-plugin.h" void slapi_search_internal_set_pb(Slapi_PBlock *pb, const char *base, int scope, const char *filter, char **attrs, int attrsonly, LDAPControl **controls, const char *uniqueid, Slapi_ComponentId *plugin_identity, int operation_flags);
This function takes the following parameters:
| pb | Parameter block that is populated with search parameters. |
| base | Search base. |
| scope | Search scope (LDAP_SCOPE_SUBTREE, etc.). |
| filter | Search filter. |
| attrs | Attributes to be returned. |
| attrsonly | Flag specifying whether to return just attribute names or names and values. |
| controls | List of controls associated with the operation. |
| uniqueid | Unique identifier of the entry. Non-NULL value indicates unique ID-based search. In this case, scope and filter are ignored; however, base is still required and is used to select the correct backend. All directory entries contain a unique identifier. Unlike the distinguished name (DN), the unique identifier of an entry never changes, providing a good way to refer unambiguously to an entry in a distributed/replicated environment. |
| plugin_identity | Plug-in identity; a cookie that identifies the plug-in to the Directory Server during an internal operation. This cookie is used by the server to retrieve the plug-in configuration in order to determine whether to allow the operation and which actions to take during the operation processing. Plug-in identity is passed to the plug-in initialization function in the SLAPI_PLUGIN_IDENTITY pblock parameter. A plug-in must save this information and pass it to every internal operation issued by the plug-in. |
| operation_flags | Actions taken during operation processing. |
The controls passed with slapi_search_internal_set_pb() must be an allocated array. Additionally, this array must be freed by slapi_pblock_destroy().
Slapi_* function.

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.