summaryrefslogtreecommitdiff
path: root/source4/ldap_server/ldap_simple_ldb.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-06-20 04:59:10 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:18:35 -0500
commitdb6933323c0997cc6334d447e9a938cb42731ae9 (patch)
tree7aee8be52e77bc7238f23f8aa13e619ea0c8465a /source4/ldap_server/ldap_simple_ldb.c
parentbd7a474b1967423711ff93c0080ce0f89270e3f9 (diff)
downloadsamba-db6933323c0997cc6334d447e9a938cb42731ae9.tar.gz
samba-db6933323c0997cc6334d447e9a938cb42731ae9.tar.bz2
samba-db6933323c0997cc6334d447e9a938cb42731ae9.zip
r7777: allow for overriding the location of the sam databasein the ldap server, using
ldapsrv:samdb option. This allows the following: sam database=ldap://localhost ldapsrv:samdb=tdb:///home/tridge/samba/samba4/prefix/private/sam.ldb which allows us to test putting the sam on an ldap server using our own ldap server. This is a great stress test for the ldap code. (This used to be commit 40948ba3848e2cfd69ee5ef77031170a652e389b)
Diffstat (limited to 'source4/ldap_server/ldap_simple_ldb.c')
-rw-r--r--source4/ldap_server/ldap_simple_ldb.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/source4/ldap_server/ldap_simple_ldb.c b/source4/ldap_server/ldap_simple_ldb.c
index 4b73026d42..e8c66e80a2 100644
--- a/source4/ldap_server/ldap_simple_ldb.c
+++ b/source4/ldap_server/ldap_simple_ldb.c
@@ -54,7 +54,7 @@ static NTSTATUS sldb_Search(struct ldapsrv_partition *partition, struct ldapsrv_
local_ctx = talloc_named(call, 0, "sldb_Search local memory context");
NT_STATUS_HAVE_NO_MEMORY(local_ctx);
- samdb = samdb_connect(local_ctx);
+ samdb = ldapsrv_sam_connect(call);
NT_STATUS_HAVE_NO_MEMORY(samdb);
basedn = ldap_parse_dn(local_ctx, r->basedn);
@@ -179,7 +179,7 @@ static NTSTATUS sldb_Add(struct ldapsrv_partition *partition, struct ldapsrv_cal
local_ctx = talloc_named(call, 0, "sldb_Add local memory context");
NT_STATUS_HAVE_NO_MEMORY(local_ctx);
- samdb = samdb_connect(local_ctx);
+ samdb = ldapsrv_sam_connect(call);
NT_STATUS_HAVE_NO_MEMORY(samdb);
dn = ldap_parse_dn(local_ctx, r->dn);
@@ -277,7 +277,7 @@ static NTSTATUS sldb_Del(struct ldapsrv_partition *partition, struct ldapsrv_cal
local_ctx = talloc_named(call, 0, "sldb_Del local memory context");
NT_STATUS_HAVE_NO_MEMORY(local_ctx);
- samdb = samdb_connect(local_ctx);
+ samdb = ldapsrv_sam_connect(call);
NT_STATUS_HAVE_NO_MEMORY(samdb);
dn = ldap_parse_dn(local_ctx, r->dn);
@@ -332,7 +332,7 @@ static NTSTATUS sldb_Modify(struct ldapsrv_partition *partition, struct ldapsrv_
local_ctx = talloc_named(call, 0, "sldb_Modify local memory context");
NT_STATUS_HAVE_NO_MEMORY(local_ctx);
- samdb = samdb_connect(local_ctx);
+ samdb = ldapsrv_sam_connect(call);
NT_STATUS_HAVE_NO_MEMORY(samdb);
dn = ldap_parse_dn(local_ctx, r->dn);
@@ -444,7 +444,7 @@ static NTSTATUS sldb_Compare(struct ldapsrv_partition *partition, struct ldapsrv
local_ctx = talloc_named(call, 0, "sldb_Compare local_memory_context");
NT_STATUS_HAVE_NO_MEMORY(local_ctx);
- samdb = samdb_connect(local_ctx);
+ samdb = ldapsrv_sam_connect(call);
NT_STATUS_HAVE_NO_MEMORY(samdb);
dn = ldap_parse_dn(local_ctx, r->dn);
@@ -512,7 +512,7 @@ static NTSTATUS sldb_ModifyDN(struct ldapsrv_partition *partition, struct ldapsr
local_ctx = talloc_named(call, 0, "sldb_ModifyDN local memory context");
NT_STATUS_HAVE_NO_MEMORY(local_ctx);
- samdb = samdb_connect(local_ctx);
+ samdb = ldapsrv_sam_connect(call);
NT_STATUS_HAVE_NO_MEMORY(samdb);
olddn = ldap_parse_dn(local_ctx, r->dn);