Parameters for the Search function

The following table lists the parameters in the parameter block that is passed to the database search function. If you are writing a pre-operation, database, or post-operation search function, you can get these values by calling the slapi_pblock_get() function.

Table 1. Parameters for the database search function
Parameter ID Data type Description
SLAPI_SEARCH_TARGET char * DN of the base entry in the search operation or the starting point of the search.
SLAPI_SEARCH_SCOPE int The scope of the search. The scope can be one of the following values:
  • LDAP_SCOPE_BASE
  • LDAP_SCOPE_ ONELEVEL
  • LDAP_SCOPE_SUBTREE
SLAPI_SEARCH_DEREF int Method for handling aliases in a search. This method can be one of the following values:
  • LDAP_DEREF_NEVER
  • LDAP_DEREF_ SEARCHING
  • LDAP_DEREF_FINDING
  • LDAP_DEREF_ALWAYS
SLAPI_SEARCH_SIZELIMIT int Maximum number of entries to return in the search results.
SLAPI_SEARCH_ TIMELIMIT int Maximum amount of time (in seconds) allowed for the search operation.
SLAPI_SEARCH_FILTER Slapi_Filter * Slapi_Filter struct (an opaque data structure) representing the filter to be used in the search.
SLAPI_SEARCH_STRFILTER char * String representation of the filter to be used in the search.
SLAPI_SEARCH_ATTRS char ** Array of attribute types to be returned in the search results.
SLAPI_SEARCH_ ATTRSONLY int Specifies whether the search results return attribute types only or attribute types and values:
  • 0 means return both attributes and values.
  • 1 means return attribute types only.
The following parameters are set by the front-end and back-end as part of the process of executing the search    
SLAPI_NENTRIES int Number of search results found.