summaryrefslogtreecommitdiff
path: root/source3/passdb/passgrpldap.c
diff options
context:
space:
mode:
authorMatthew Chapman <matty@samba.org>1999-01-15 05:00:26 +0000
committerMatthew Chapman <matty@samba.org>1999-01-15 05:00:26 +0000
commitc35bf4578561af4f2971492f6ef826f10ac13860 (patch)
treef3f7487aea242103660e6263949b6e60395a0a5a /source3/passdb/passgrpldap.c
parentb86b8a3ea887e12f0614e14da01419e5c224d038 (diff)
downloadsamba-c35bf4578561af4f2971492f6ef826f10ac13860.tar.gz
samba-c35bf4578561af4f2971492f6ef826f10ac13860.tar.bz2
samba-c35bf4578561af4f2971492f6ef826f10ac13860.zip
Finally committing my LDAP changes.
* Added new APIs for modifying groups. * RIDs are allocated similarly to NT, starting from 1000 and incrementing by 1 for each new user/group. * RIDs are now consistently in hex * Fixed bugs reported by Allan Bjorklund <allan@umich.edu>: - ldap_close_connection is exported by OpenLDAP - changed to ldap_disconnect - Missing ldap_connect() in getusergroups functions - ldap_next_entry was being called too early while retrieving a sam_struct - LDAP globals should be extern in sampassldap.c * Fixed bugs reported by Martin Hofbauer <mh@bacher.at> - Newly added workstation trust accounts had attributes DU rather than W. - User dn's were forced to start with "uid=XX" rather than using the existing dn. (This used to be commit 91c77f5432169553572bb4d85ad5f09d17524f20)
Diffstat (limited to 'source3/passdb/passgrpldap.c')
-rw-r--r--source3/passdb/passgrpldap.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source3/passdb/passgrpldap.c b/source3/passdb/passgrpldap.c
index 3d647cd776..1092a3c5b1 100644
--- a/source3/passdb/passgrpldap.c
+++ b/source3/passdb/passgrpldap.c
@@ -66,7 +66,7 @@ static void ldappassgrp_member(char *attribute, uint32 **rids, int *numrids)
static void *ldappassgrp_enumfirst(BOOL update)
{
- if (!ldap_open_connection(False))
+ if (!ldap_connect())
return NULL;
ldap_search_for("&(objectclass=sambaAccount)(|(group=*)(alias=*))");
@@ -76,7 +76,7 @@ static void *ldappassgrp_enumfirst(BOOL update)
static void ldappassgrp_enumclose(void *vp)
{
- ldap_close_connection();
+ ldap_disconnect();
}
@@ -106,7 +106,7 @@ static struct smb_passwd *ldappassgrp_getpwbynam(const char *name,
{
struct smb_passwd *ret;
- if(!ldap_open_connection(False))
+ if(!ldap_connect())
return NULL;
ldap_search_by_ntname(name);
@@ -114,7 +114,7 @@ static struct smb_passwd *ldappassgrp_getpwbynam(const char *name,
ldappassgrp_member("alias", als_rids, num_alss);
ret = ldap_getpw();
- ldap_close_connection();
+ ldap_disconnect();
return ret;
}
@@ -124,7 +124,7 @@ static struct smb_passwd *ldappassgrp_getpwbyuid(uid_t userid,
{
struct smb_passwd *ret;
- if(!ldap_open_connection(False))
+ if(!ldap_connect())
return NULL;
ldap_search_by_uid(userid);
@@ -132,7 +132,7 @@ static struct smb_passwd *ldappassgrp_getpwbyuid(uid_t userid,
ldappassgrp_member("alias", als_rids, num_alss);
ret = ldap_getpw();
- ldap_close_connection();
+ ldap_disconnect();
return ret;
}
@@ -142,7 +142,7 @@ static struct smb_passwd *ldappassgrp_getpwbyrid(uint32 user_rid,
{
struct smb_passwd *ret;
- if(!ldap_open_connection(False))
+ if(!ldap_connect())
return NULL;
ldap_search_by_rid(user_rid);
@@ -150,7 +150,7 @@ static struct smb_passwd *ldappassgrp_getpwbyrid(uint32 user_rid,
ldappassgrp_member("alias", als_rids, num_alss);
ret = ldap_getpw();
- ldap_close_connection();
+ ldap_disconnect();
return ret;
}