[Remove entries to the current 2.0 section below, when backported]
+ *) Fix a potential segfault if the bind password in the LDAP cache
+ is NULL. PR 26686 [Jari Ahonen <jah@progress.com>]
+
*) Quotes cannot be used around require group and require dn
directives, update the documentation to reflect this. Also add
quotes around the dn and group within debug messages, to make it
newnode->vals = NULL;
}
if (!(newnode->username = util_ald_strdup(cache, node->username)) ||
- !(newnode->dn = util_ald_strdup(cache, node->dn)) ||
- !(newnode->bindpw = util_ald_strdup(cache, node->bindpw)) ) {
+ !(newnode->dn = util_ald_strdup(cache, node->dn)) ) {
util_ldap_search_node_free(cache, newnode);
return NULL;
}
+ if(node->bindpw) {
+ if(!(newnode->bindpw = util_ald_strdup(cache, node->bindpw))) {
+ util_ldap_search_node_free(cache, newnode);
+ return NULL;
+ }
+ } else {
+ newnode->bindpw = NULL;
+ }
newnode->lastbind = node->lastbind;
}