From 2a9c7462c7e45ccfc57d5c6943c344980b71d631 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Sun, 6 May 2007 21:17:02 +0000 Subject: r22717: Add Everyone and AuthenticatedUsers to the user's token for use by the require-membership-of pam_winbind option. (This used to be commit 11f81c5997a014cca9d98c474e7870ebb07c4642) --- source3/nsswitch/winbindd_pam.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/source3/nsswitch/winbindd_pam.c b/source3/nsswitch/winbindd_pam.c index d9c9fe91cb..66ac61e5c9 100644 --- a/source3/nsswitch/winbindd_pam.c +++ b/source3/nsswitch/winbindd_pam.c @@ -128,7 +128,11 @@ static NTSTATUS check_info3_in_group(TALLOC_CTX *mem_ctx, DOM_SID *require_membership_of_sid; size_t num_require_membership_of_sid; DOM_SID *all_sids; - size_t num_all_sids = (2 + info3->num_groups2 + info3->num_other_sids); + /* UserSID, GroupSID, Grooup2SIDs, OtherSIDs, WellKnownSIDs */ + size_t num_all_sids = (2 + + info3->num_groups2 + + info3->num_other_sids + + 2 ); size_t i, j = 0, k; size_t group_sid_length; const char *search_location; @@ -213,6 +217,11 @@ static NTSTATUS check_info3_in_group(TALLOC_CTX *mem_ctx, } j++; + /* Well-Known SIDs */ + + sid_copy( &all_sids[j++], &global_sid_World ); + sid_copy( &all_sids[j++], &global_sid_Authenticated_Users ); + for (i = 0; i < info3->num_groups2; i++) { sid_copy(&all_sids[j], &(info3->dom_sid.sid)); -- cgit