Returns string values of a specified attribute from an entry.
#include <ldap.h>
char **ldap_get_values (
LDAP *ld,
LDAPMessage *entry,
const char *attr);
(IN) Points to the handle for the LDAP session.
(IN) Points to the entry returned by the ldap_first_entry or the ldap_next_entry function.
(IN) Points to the attribute returned by the ldap_first_attribute function, the ldap_next_attribute function, or the name of an attribute in string format.
The ldap_get_values function takes an entry and attribute and returns a NULL-terminated array of attribute string values. The memory for the array is dynamically allocated. When you are done with the array, free the memory by calling the ldap_value_free function.
The ldap_get_values function can be used to return only character string values. For binary data, use the ldap_get_values_len function.