mirror of
https://github.com/samba-team/samba.git
synced 2025-03-08 04:58:40 +03:00
r19579: BUG 4075: patch from Dmitry Butskoy <dmitry@butskoy.name>.
Allow smbd to use winbindd to lookup uids/gids outside the idmap range if 'winbind trusted domains only = yes' (This used to be commit 5b3ac400a7d51dfc818563189bdf6649b2dc3a52)
This commit is contained in:
parent
f8fc3f9158
commit
cd41945acc
@ -1124,7 +1124,8 @@ void uid_to_sid(DOM_SID *psid, uid_t uid)
|
||||
if (fetch_sid_from_uid_cache(psid, uid))
|
||||
return;
|
||||
|
||||
if (lp_idmap_uid(&low, &high) && (uid >= low) && (uid <= high) &&
|
||||
if ((lp_winbind_trusted_domains_only() ||
|
||||
(lp_idmap_uid(&low, &high) && (uid >= low) && (uid <= high))) &&
|
||||
winbind_uid_to_sid(psid, uid)) {
|
||||
|
||||
DEBUG(10,("uid_to_sid: winbindd %u -> %s\n",
|
||||
@ -1169,7 +1170,8 @@ void gid_to_sid(DOM_SID *psid, gid_t gid)
|
||||
if (fetch_sid_from_gid_cache(psid, gid))
|
||||
return;
|
||||
|
||||
if (lp_idmap_gid(&low, &high) && (gid >= low) && (gid <= high) &&
|
||||
if ((lp_winbind_trusted_domains_only() ||
|
||||
(lp_idmap_gid(&low, &high) && (gid >= low) && (gid <= high))) &&
|
||||
winbind_gid_to_sid(psid, gid)) {
|
||||
|
||||
DEBUG(10,("gid_to_sid: winbindd %u -> %s\n",
|
||||
|
Loading…
x
Reference in New Issue
Block a user