From 35f4ea221e75ebb4101cbacc6bc24bd1a3604f0f Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Tue, 3 Mar 2009 16:08:56 -0800 Subject: Fix bug #6155 - "force group" is no longer working as expected. We need to store the "force group" uid separately from the conn->server_info token as we need to apply it separately also. Volker PLEASE CHECK ! Jeremy. --- source3/smbd/service.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'source3/smbd/service.c') diff --git a/source3/smbd/service.c b/source3/smbd/service.c index dcdd69f997..eb16a2601e 100644 --- a/source3/smbd/service.c +++ b/source3/smbd/service.c @@ -833,6 +833,14 @@ static connection_struct *make_connection_snum(int snum, user_struct *vuser, *pstatus = status; return NULL; } + + /* + * We need to cache this gid, to use within + * change_to_user() separately from the conn->server_info + * struct. We only use conn->server_info directly if + * "force_user" was set. + */ + conn->force_group_gid = conn->server_info->utok.gid; } conn->vuid = (vuser != NULL) ? vuser->vuid : UID_FIELD_INVALID; -- cgit