summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2012-12-03 01:42:38 +0100
committerStefan Metzmacher <metze@samba.org>2012-12-03 08:48:30 +0100
commita0f41294488fcf4c9dbe5e85be6539394b6d6d1a (patch)
tree7c0a1af3309fca1c7d918cb7dfc8035e1d180293 /source3
parent671f534e5e02adafe945a4e77813e80b5adaeb70 (diff)
downloadsamba-a0f41294488fcf4c9dbe5e85be6539394b6d6d1a.tar.gz
samba-a0f41294488fcf4c9dbe5e85be6539394b6d6d1a.tar.bz2
samba-a0f41294488fcf4c9dbe5e85be6539394b6d6d1a.zip
s3:passdb:pdb_ldap: pre-validate sid with sid_check_object_is_for_passdb()
instead of sid_check_sid_is_in_our_sam). This allows for builtin sids, wellknown sids and "Unix User" and "Unix Group" domains. This broadens up the check moved here in commit 02e25b2a43ae02205a3412f862a1482d24b70aa4. Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/passdb/pdb_ldap.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c
index a5b8f0b18a..5bbfb2bc3a 100644
--- a/source3/passdb/pdb_ldap.c
+++ b/source3/passdb/pdb_ldap.c
@@ -53,6 +53,7 @@
#include "lib/winbind_util.h"
#include "librpc/gen_ndr/idmap.h"
#include "lib/param/loadparm.h"
+#include "lib/util_sid_passdb.h"
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_PASSDB
@@ -4915,9 +4916,8 @@ static bool ldapsam_sid_to_id(struct pdb_methods *methods,
TALLOC_CTX *mem_ctx;
- if (!sid_check_is_in_our_sam(sid)) {
- /* Not our SID */
- return False;
+ if (!sid_check_object_is_for_passdb(sid)) {
+ return false;
}
mem_ctx = talloc_new(NULL);