diff options
author | Christian Ambach <ambi@samba.org> | 2013-06-18 10:47:33 +0200 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2013-06-21 10:44:21 +0200 |
commit | 987de8a971bf9730c92406234d4a0f3a23a92dda (patch) | |
tree | 21ff3ab4de618a67a4067180f833c108ccf21159 /source3/passdb | |
parent | 55dd9e6a9cf70fbead0a7af277da092ded221d46 (diff) | |
download | samba-987de8a971bf9730c92406234d4a0f3a23a92dda.tar.gz samba-987de8a971bf9730c92406234d4a0f3a23a92dda.tar.bz2 samba-987de8a971bf9730c92406234d4a0f3a23a92dda.zip |
s3:passdb make pdb_sid_to_id honor backend responsibilities
only ask passdb backend for mapping if it is responsible
Pair-Programmed-With: Michael Adam <obnox@samba.org>
Signed-off-by: Christian Ambach <ambi@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'source3/passdb')
-rw-r--r-- | source3/passdb/pdb_interface.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source3/passdb/pdb_interface.c b/source3/passdb/pdb_interface.c index b45b4d66bb..ea67e2faf5 100644 --- a/source3/passdb/pdb_interface.c +++ b/source3/passdb/pdb_interface.c @@ -34,6 +34,7 @@ #include "../libcli/security/security.h" #include "../lib/util/util_pw.h" #include "passdb/pdb_secrets.h" +#include "lib/util_sid_passdb.h" #undef DBGC_CLASS #define DBGC_CLASS DBGC_PASSDB @@ -1217,6 +1218,12 @@ bool pdb_gid_to_sid(gid_t gid, struct dom_sid *sid) bool pdb_sid_to_id(const struct dom_sid *sid, struct unixid *id) { struct pdb_methods *pdb = pdb_get_methods(); + + /* only ask the backend if it is responsible */ + if (!sid_check_object_is_for_passdb(sid)) { + return false; + } + return pdb->sid_to_id(pdb, sid, id); } |