17.7. slapi_search_internal_get_entry()

This function performs an internal search operation to read one entry; that is, it performs a base object search. If an entry named by dn is found, the ret_entry pointer will be set to point to a copy of the entry that contains the attribute values specified by the attrlist parameter.
#include "slapi-plugin.h"
int slapi_search_internal_get_entry( Slapi_DN *dn, char ** attrlist, Slapi_Entry **ret_entry, void *caller_identity);
This function takes the following parameters:
dn The DN of the entry to be read.
attrlist A NULL terminated array of attribute types to return from entries that match filter. If you specify a NULL, all attributes will be returned.
ret_entry The address of a pointer to receive the entry if it is found.
caller_identity A plug-in or component identifier. This value can be obtained from the SLAPI_PLUGIN_IDENTITY field of the parameter block that is passed to your plug-in initialization function.
This function returns the LDAP result code for the search operation.
Memory Concerns
The returned entry (*ret_entry) should be freed by calling slapi_entry_free().
See Also